getMissingSubtitles() CLI arguments behaviour
Posted: 19 Nov 2014, 12:58
This is my simplified groovy script
1. With filebot -script myscript.groovy -non-strict -unixfs <path>
Missing subtitles are retrieved and renamed correctly.
Renaming videos is missing the DB and trying to guess. I have not intensively tested, so I ignore if it is reliable, probably not.
2. With filebot -script myscript.groovy -non-strict -unixfs --db TheMovieDB<path>
Renaming videos works correctly
Matching subtitles are not found, I do not know why, as if it would have turned to strict mode despite the CLI -no-strict. Adding strict: true to getMissingSubtitles() does not help.
3. Adding --action test to the CLI
Renaming videos does a dry run as expected
Retrieving subtitles ignores it, and does a full run.
Are these bugs or it works as designed?
4. If getMissingSubtitles() would support format, it would spare us some extra renaming
Code: Select all
// Read format from file
String format = new File('myscript.format').text
// Rename only videos and subtitles
rename(file: args.getFiles{ it.isVideo() || it.isSubtitle() },format: format)
// Get missing subtitles and rename only the new ones
subs=getMissingSubtitles(file: args.getFiles{ it.isVideo() }, lang: 'English')
if (subs) rename(file: subs, format: format)
subs=getMissingSubtitles(file: args.getFiles{ it.isVideo() }, lang: 'Spanish')
if (subs) rename(file: subs, format: format)
Missing subtitles are retrieved and renamed correctly.
Renaming videos is missing the DB and trying to guess. I have not intensively tested, so I ignore if it is reliable, probably not.
2. With filebot -script myscript.groovy -non-strict -unixfs --db TheMovieDB<path>
Renaming videos works correctly
Matching subtitles are not found, I do not know why, as if it would have turned to strict mode despite the CLI -no-strict. Adding strict: true to getMissingSubtitles() does not help.
3. Adding --action test to the CLI
Renaming videos does a dry run as expected
Retrieving subtitles ignores it, and does a full run.
Are these bugs or it works as designed?
4. If getMissingSubtitles() would support format, it would spare us some extra renaming