How do I add {imdb-tt0416449} to movie file names?

All about user-defined episode / movie / file name format expressions
Post Reply
UnknownUser
Posts: 3
Joined: 19 Aug 2022, 14:15

How do I add {imdb-tt0416449} to movie file names?

Post by UnknownUser »

Hello I just installed filebot and have a question.

How do I simply add information to a title? For example. The file is called "300 (2007) - Director's Cut.mkv". Now I would like to keep the name like it is, but simply add "{imdb-tt0416449}" to it.

Expected result "300 (2007) - Director's Cut {imdb-tt0416449}.mkv"
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: How to add informations to a title

Post by rednoah »

e.g. I'd recreate your naming pattern via a custom format like so:

Code: Select all

{ ny }{ " - " + tags }{ " {imdb-$imdbid}" }
:idea: Please read the FAQ and How to Request Help.
UnknownUser
Posts: 3
Joined: 19 Aug 2022, 14:15

Re: How do I add {imdb-tt0416449} to movie file names?

Post by UnknownUser »

Thank you, but after the - there aren't always tags, so I managed to solve it like this

Code: Select all

{fn} {"{imdb-$imdbid}"}
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: How do I add {imdb-tt0416449} to movie file names?

Post by rednoah »

This snippet will match patterns such as Director's Cut from the original file name and prepend a dash:

Code: Select all

{ " - " + tags }
It notably does not require the original file name to contain any tags, or follow any particular naming pattern. If { tags } yields no value then { " - " + tags } yield no value either, and no - followed by nothing either.



:!: This can work, but if you don't use {ny} then you have absolutely no chance of spotting mismatches and you might end up with an incorrect imdb numbers in one or two files and that could be a problem later:

Code: Select all

{fn} {"{imdb-$imdbid}"}
:idea: Please read the FAQ and How to Request Help.
UnknownUser
Posts: 3
Joined: 19 Aug 2022, 14:15

Re: How do I add {imdb-tt0416449} to movie file names?

Post by UnknownUser »

My naming scheme wasn't as consistent that I could have recreated it with an automation. Or at least I wouldn't know how to with so many variables. That's why I tried to keep everything how it was, while only adding this tag to make it easier for Plex to match them. It was somewhat of a manual process anyway with matching and after that verifying if it got everything right. But I still saved a lot of time considering it were over 1000 files
Post Reply