Page 1 of 1

Multiple version of SRT, same lang

Posted: 02 Jan 2023, 19:26
by aglyons
I have come across situations where there are multiple ENG subtitle files. Is there a way for FB to identify these and keep all of the same language SRTs? Possibly increment the file count with a postfix (i.e., eng-1, eng-2 etc.)?

This happens when there is a general subtitle file with all dialogue captured. There are other SRTs with forced foreign language captions (as in an English movie with characters speaking Spanish). Currently, FB will pick the first language match and disregard the rest. The thing is, we don't know in advance which SRT contains what without doing a manual check (which defeats the concept of automating this stuff).

Re: Multiple version of SRT, same lang

Posted: 03 Jan 2023, 02:06
by rednoah
{subt} will just work for well-named subtitles and preserve the subtitle type:

Code: Select all

.eng.srt
.eng-forced.srt
.eng-HI.srt
.eng-CC.srt
.eng-SDH.srt

However, if your files are badly named, then you will have to find a custom solution:

Code: Select all

.eng-1.srt
.eng-2.srt

FileBot will process these files just fine. But your format needs to come up with unique target file paths for each unique input file path.

e.g. match the trailing -1 pattern from the original file name

Code: Select all

{ subt }{ fn.match(/[._-][0-9]$/) }
:idea: Please read [SNIPPET] Match information from the file path for details.




Related Topics:

Re: Multiple version of SRT, same lang

Posted: 03 Jan 2023, 03:44
by rednoah