File numbering inconsistent in character placement

Post any Bulk Rename Utility support requirements here. Open to all registered users.

File numbering inconsistent in character placement

Postby sufojareth » Mon Jul 31, 2023 12:55 pm

Hello all!

I am currently trying to organize a TV series for proper metadata reading on my Plex server. Currently ran into a snag at the very start renaming folders before I even get to the episodes. I think it will be easier for me to attach a screenshot to show my issue. The issue is pretty obvious looking at the highlighted folder and the new column.

Thank you for any help that can be given.

Image
sufojareth
 
Posts: 2
Joined: Mon Jul 31, 2023 12:50 pm

Re: File numbering inconsistent in character placement

Postby therube » Mon Jul 31, 2023 4:22 pm

If all your episodes are laid out as shown, I think this will work:

1:RegEx, enable Simple
Code: Select all
Match:  %1 - %2%3%4%5 (%6) %7
Replace:  %1 - Season %3%4 Serial %6

The only difference is that Season will be 2-digits, 0# or 1#. (01..09 ... 11..19, ...)

%1 matches, dr. who
%2%3%4%5 matches, (2 3 4) s 0 7, (5) e01 (5, being a catch-all for the remainder of the s07e01 string)
%6 matches, the "Serial" number
%7 is simply a catch-all for everything else

Then it is simply a matter (in the Replace:) of choosing what you want, & adding the "static" terms.

Code: Select all
doctor who - s07e01 (051) spearhead from space - parts 1-4
->   doctor who - Season 07 Serial 051
doctor who - s07e02 (052) abcblob - parts 1-4
->   doctor who - Season 07 Serial 052
therube
 
Posts: 1319
Joined: Mon Jan 18, 2016 6:23 pm

Re: File numbering inconsistent in character placement

Postby Luuk » Mon Jul 31, 2023 5:30 pm

Therube's answer should conduct most of your names properly, with having a checkmark inside for "Simple".
If wanting something more exact, can remove the checkmark, with a "Match" and "Replace" like...
(.+) S(\d+)E\d+ \((\d+[a-d]?)\).+?( ?\([^()]+\)|$)
\1 Season \2 Serial \3\4

If wanting to remove leading-zeros, can edit the "Match" like...
(.+) S0*(\d+)E\d+ \(0*(\d+[a-d]?)\).+?( ?\([^()]+\)|$)
Luuk
 
Posts: 706
Joined: Fri Feb 21, 2020 10:58 pm

Re: File numbering inconsistent in character placement

Postby sufojareth » Tue Aug 01, 2023 11:20 am

Both of these responses were very helpful and helped me understand the program a bit more. Thank you very much! All is working as I would like now.
sufojareth
 
Posts: 2
Joined: Mon Jul 31, 2023 12:50 pm


Return to BRU Support


cron