feat(roadmap): surface stale checkboxes + collection output-path setting
Command preview + incognito toggle were already wired end-to-end in the DownloadBar (Show command button, Incognito checkbox) — flipped the two stale ROADMAP.md checkboxes with notes; verified live in the preview. Output-path setting (PINCHFLAT): new Settings.collectionOutputTemplate — a raw yt-dlp -o template overriding the default Channel/Playlist/NNN-Title layout for Library downloads (empty = default). collectionOutputTemplate() takes an optional custom template (joined under outDir, left for yt-dlp to expand); download.ts passes the setting; zod schema validates it as a safe relative template; Settings -> Filenames field. Tests in buildArgs + settingsSchema; live-verified the field renders. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -735,6 +735,27 @@ describe('collectionOutputTemplate', () => {
|
||||
)
|
||||
expect(t.replace(/\\/g, '/')).toBe('C:/out/A B/Untitled/001 - %(title)s.%(ext)s')
|
||||
})
|
||||
|
||||
it('a custom template overrides the built-in layout and is left for yt-dlp to expand', () => {
|
||||
const t = collectionOutputTemplate(
|
||||
'C:/out',
|
||||
ctx,
|
||||
'%(title)s.%(ext)s',
|
||||
'%(uploader)s/%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s'
|
||||
)
|
||||
expect(t.replace(/\\/g, '/')).toBe(
|
||||
'C:/out/%(uploader)s/%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s'
|
||||
)
|
||||
})
|
||||
|
||||
it('a blank/whitespace custom template falls back to the built-in layout', () => {
|
||||
expect(collectionOutputTemplate('C:/o', ctx, 'f', '').replace(/\\/g, '/')).toBe(
|
||||
'C:/o/DevChannel/Full Course/003 - f'
|
||||
)
|
||||
expect(collectionOutputTemplate('C:/o', ctx, 'f', ' ').replace(/\\/g, '/')).toBe(
|
||||
'C:/o/DevChannel/Full Course/003 - f'
|
||||
)
|
||||
})
|
||||
})
|
||||
|
||||
describe('metadata overrides (--replace-in-metadata)', () => {
|
||||
|
||||
Reference in New Issue
Block a user