Page 1 of 1

Rename by country of origin

Posted: 26 Mar 2020, 07:08
by katak
Hello,

I watch 90% english movies and 10% french movies:
- I have to switch language each time I want the right name
- I have been thinking (yes it happens)

Can you add an option where renaming will depend on movie origin ? :)

Thanks

Re: Rename by country of origin

Posted: 26 Mar 2020, 07:49
by rednoah
1.
{languages} will give you the Spoken Languages as defined by TheMovieDB. Alternatively, you can use {audioLanguages} which relies solely on MediaInfo. {info.ProductionCountries} could be an option if you care about the production country rather than the spoken language.


2.
These values can then be used in the file name, or for if-then-else conditions:
viewtopic.php?t=4191

Re: Rename by country of origin

Posted: 26 Mar 2020, 07:55
by katak
Hi,

Sorry I don't get, when I use this in file editor it gives language information after rename but I'd like french name for french movie actors and english name for english movie actors.

perhaps I did not treat your feedback well, sorry in that case.

Re: Rename by country of origin

Posted: 26 Mar 2020, 07:59
by rednoah
If you want clear & specific help, please provide clear & specific examples and goals:
* representative input file path for each unique use case
* example for the preferred destination file path for each unique use case

Re: Rename by country of origin

Posted: 26 Mar 2020, 09:40
by katak
I will show one example with french donwloaded movies:
1. J'accuse-2019.mkv from Polanski
2. Les_diamants_sont_├ęternels.mkv, James Bond Movie

With the feature I am talking about it will give:
1. "J'accuse - 2019.mkv" instead of "an officier and a spy.mkv" with english search => French actor so I keep french name
2. "Diamonds are eternal.mkv" => English movie so the name given is in english

Do you see what I mean ?

Re: Rename by country of origin

Posted: 26 Mar 2020, 09:52
by rednoah
I think this covers your use case:
viewtopic.php?t=3761

e.g.

Code: Select all

{localize[languages[0]].plex}

Re: Rename by country of origin

Posted: 26 Mar 2020, 13:36
by katak
Sorry but I'm a newbie and I do not knwo where to put this code:

Code: Select all

{localize[languages[0]].n}
Thank you

Re: Rename by country of origin

Posted: 26 Mar 2020, 13:48
by rednoah
You can use that as part of your custom format:
https://www.filebot.net/naming.html

Image

Re: Rename by country of origin

Posted: 26 Mar 2020, 14:23
by katak

Code: Select all

{audio.language =~ /en/ ? localize.en.n : n} ({y}){' CD'+pi}{subt}
It works ! :)

Thank you