How to get "Season 01" in a filename/path on rename?

All your suggestions, requests and ideas for future development
Post Reply
aimba
Posts: 1
Joined: 26 Jan 2019, 02:20

How to get "Season 01" in a filename/path on rename?

Post by aimba »

I like to move/rename my files into a structure that has season folders, with leading zeroes for single digit numbers.

While s00e00 does S01 instead of S1, I cannot do /Season {s00}/ by itself to get a "Season 01" in my path.

Obviously I could do /Season 0{s}/ but then seasons larger than 9 get a leading 0 as well and the whole thing breaks again.

What's the right way to use the tokens to get "Season 01" and "Season 22" with the same code (i.e. not "Season 022/ 01"?
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: How to get "Season 01" in a filename/path on rename?

Post by rednoah »

1.
You can 0-pad the season number to 2-digits like so:

Code: Select all

{s.pad(2)}
Please have a look at the format examples:
https://www.filebot.net/naming.html


2.
Why not just use the {plex} binding?
viewtopic.php?f=5&t=4116
:idea: Please read the FAQ and How to Request Help.
Post Reply