1a. if so is there any reason to add that? will FileBot detect to match it to find the correct episode.
If not, it would be useful for times when FileBot keeps pulling the incorrect episode at times.)
2. Is it possible to detect if the file has HDR, Atmos, or Dolby Digital?
3. What is the best way to detect the language in the file?
I currently have:
Code: Select all
{if (audio.LanguageString[2]) '[Triple Audio]' }{if (audio.LanguageString[1]) '[Dual Audio]' }} {any{if (audio.LanguageString[1]) {audio.LanguageString.unique().join(', ')}}{file.path.lower().replaceAll(/cn/,'Chinese').matchAll(/afrikaans[\. ]|albanian[\. ]|arabic[\. ]|burmese[\. ]|danish[\. ]|deutsch[\. ]|dutch[\. ]|english[\. ]|finnish[\. ]|french[\., ]|hebrew[\. ]|hindi[\. ]|hungarian[\. ]|icelandic[\. ]|indonesian[\. ]|italiano[\. ]|italian[\. ]|italian[\. ]|japanese[\. ]|korean[\. ]|navajo[\. ]|norwegian[\. ]|polish[\. ]|portuguese[\. ]|punjabi[\. ]|romanian[\. ]|scottish gaelic[\. ]|scottish[\. ]|spanish[\. ]|swahili[\. ]|swedish[\. ]|tagalog[\. ]|thai[\. ]|tibetan[\. ]|vietnamese[\. ]|yiddish[\. ]|slovak[\. ]|greek[\. ]|chinese[\. ]|czech[\. ]|german[\. ]|latvian[\. ]|russian[\. ]|serbian /).unique()*.upperInitial()*.lowerTrail().sort().join(', ')}{any{file.path.match(/dual.audio/)+' '}{info.SpokenLanguages.displayLanguage =~ /eng|en|English|Unknown|Unspecified/ ? 'English' : info.SpokenLanguages.displayLanguage.unique().join(', ').replace('cn','Chinese')}{'Unspecified Language'}}}
but that doesn't seem efficient. as you can see it's looking in the filename. then it'll look for the spoken language. and if not listed it'll put it as unknown. but that usually is English, i've found.
So i was wondering if there is a better way to detect the audio language then add the language to the filename. (unless it's got multiple tracks then just have it add dual audio, triple audio, etc.
Any help or suggestions would be appreciated.
Thanks
-Dev