A quoted name that runs on into a title; .xNNN/.zNNN volumes
"lois 1258 Billy Joel - Extremes.part01.rar lois 1258 Billy Joel - Extremes ",
"GrooveCoverage.part26.rarGrooveCoveragebestof", "Goga Sekulic.part134.rar -
Goga Sekulic - …": the stem kept the title, and each part was a release of its
own (lois, CPP, DieViper, Maveri, tigra: ~2,400 files). runOn cuts the name
after its archive extension when a space, a dash or the name's own start
follows. And three-digit .x/.z volumes ("Reply 987986177631730.x004"),
not .x264/.x265.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
1c8da1dd12
commit
0c5ede99dd
4 files changed
+89
-12
No files matched your search
@@ -1,5 +1,5 @@
|
||||
import { test } from '@japa/runner'
|
||||
import { fileStem, releaseIdentity, sizeAfterName, subjectRemainder } from '#lib/release/index'
|
||||
import { fileStem, releaseIdentity, runOn, sizeAfterName, subjectRemainder } from '#lib/release/index'
|
||||
import { looksLikeFilename, weakFileKey } from '#lib/headers/index'
|
||||
|
||||
test.group('release / fileStem', () => {
|
||||
@@ -308,6 +308,16 @@ test.group('release / par2 names', () => {
|
||||
assert.equal(fileStem('App.x86'), 'App.x86')
|
||||
assert.equal(fileStem('Licence 700790900887990.z18'), 'Licence 700790900887990')
|
||||
assert.equal(fileStem('Licence 077887994400668.x12'), 'Licence 077887994400668')
|
||||
assert.equal(fileStem('Reply 987986177631730.x004'), 'Reply 987986177631730')
|
||||
assert.equal(fileStem('Some.Movie.2010.x264'), 'Some.Movie.2010.x264')
|
||||
assert.equal(runOn('lois 1258 Billy Joel - Extremes.part01.rar lois 1258 Billy Joel - Extremes '), 'lois 1258 Billy Joel - Extremes.part01.rar')
|
||||
assert.equal(runOn('GrooveCoverage.part26.rarGrooveCoveragebestof'), 'GrooveCoverage.part26.rar')
|
||||
assert.equal(runOn('Goga Sekulic.part134.rar - Goga Sekulic - Diskografija (2000-2014).'), 'Goga Sekulic.part134.rar')
|
||||
assert.equal(runOn('HASf293jLAIWUELvhaG3.part091.rar HASf293jLAIWUELvhaG3'), 'HASf293jLAIWUELvhaG3.part091.rar')
|
||||
assert.equal(runOn('Movie.rar.Collection.mkv'), 'Movie.rar.Collection.mkv')
|
||||
assert.equal(runOn('x.part01.rar'), 'x.part01.rar')
|
||||
const lois = (i: string, n: string) => releaseIdentity({ poster: 'p', subject: `(thnx to original poster) [${i}/92] - "${n}" yEnc`, name: n, weak: false })!
|
||||
assert.equal(lois('02', 'lois 1258 Billy Joel - Extremes.part01.rar lois 1258 Billy Joel - Extremes ').key, lois('01', 'lois 1258 Billy Joel - Extremes.par2 lois 1258 Billy Joel - Extremes ').key)
|
||||
assert.equal(fileStem('chappelle1.part02.rev'), 'chappelle1')
|
||||
assert.equal(fileStem('chappelle1.rev'), 'chappelle1')
|
||||
assert.equal(fileStem('VwE3i90MVX9dqMFuDfzdS7Q6.part1.par2'), 'VwE3i90MVX9dqMFuDfzdS7Q6')
|
||||
|
||||
Reference in new issue
Block a user