If English is the one and only audio than move to specific folder

All about user-defined episode / movie / file name format expressions
Post Reply
Burak
Posts: 8
Joined: 01 Oct 2019, 13:49

If English is the one and only audio than move to specific folder

Post by Burak »

Hi,

First of all, English is not my primary language. So, sorry for my bad language.

I have a question.

I want to separate folders with this rule:

If English is the one and only audio language than move the file English Movies.

Thanks for help
User avatar
rednoah
The Source
Posts: 22984
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: If English is the one and only audio than move to specific folder

Post by rednoah »

e.g.

Code: Select all

{audioLanguages ==~ /.eng./ ? 'English Movies' : 'Other Movies'}
:idea: Please read the FAQ and How to Request Help.
Burak
Posts: 8
Joined: 01 Oct 2019, 13:49

Re: If English is the one and only audio than move to specific folder

Post by Burak »

thank you, it worked!
fireheart2008
Posts: 37
Joined: 29 Jul 2014, 05:39

Re: If English is the one and only audio than move to specific folder

Post by fireheart2008 »

it looks like this is an old topic however it piqued my interest , i think i can improve on the given reply.
while using tmdb as database for movies or series , if you want to categorize based on language then the best and most accurate binding to use should be

Code: Select all

info.OriginalLanguage
some examples from my own formula

Code: Select all

{info.OriginalLanguage=~ /ar/ ? '[Arabic]/' :null}

Code: Select all

{'Animation' in genres ? '[Animation]/' : (!(info.OriginalLanguage=~ /ar/) && !(info.OriginalLanguage=~ /en/) ) ? '[Non-English]/' : null}

Code: Select all

{if (info.OriginalLanguage=~ /ar/)  (primaryTitle) else norm(n)}

Code: Select all

{episode.special ? n + ' S00E'+special.pad(2) : languages[0]=~ /jpn/ && genres.contains('Animation') ? n +' E' + absolute.pad(2) : n+' '+s00e00}
fireheart2008
Posts: 37
Joined: 29 Jul 2014, 05:39

Re: If English is the one and only audio than move to specific folder

Post by fireheart2008 »

or what the original poster asks for

Code: Select all

{(info.OriginalLanguage=~ /en/) ? 'English Movies' : 'Other Movies'}
User avatar
rednoah
The Source
Posts: 22984
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: If English is the one and only audio than move to specific folder

Post by rednoah »

The choice between audioLanguages and info.OriginalLanguage is ultimately up to the user. It's Apples and Bananas, pick the one that you want to eat. :lol:

audioLanguages is based on the MediaInfo / Audio Stream(s) of the given file (regardless of matched movie object)

info.OriginalLanguage is whatever has been entered on TheMovieDB for the particular matched movie object (regardless of what audio streams are actually available inside the given file)
:idea: Please read the FAQ and How to Request Help.
Post Reply