Filebot = Sonarr naming scheme

Support for Windows users
Post Reply
casperse
Posts: 29
Joined: 19 Aug 2017, 09:17

Filebot = Sonarr naming scheme

Post by casperse »

Hi All

I am trying to get the to naming schemes aligned in order to use them both side by side.
But I found an error in the scheme of special characters like ":" this creates problems in file names and directories naming.

Example Sonarr:
Formula 1 - Drive to Survive\Season 01\Formula 1 - Drive to Survive - s01e01 - All to Play For [WEB-DL.1080p.x264.8Bit.AC3.6ch].mkv

Code: Select all

(Series Title} - s{season:00}e{episode:00} - {Episode Title} [{Quality Title}.{MediaInfo.Simple}.{MediaInfo VideoDynamicRange}.{MediaInfo AudioFormat}.{MediaInfo AudioChannels}]

Example Filebot:
Formula 1: Drive to Survive\Formula 1: Drive to Survive - s01e01 - All to Play For [WEB-DL.1080p.x264.8Bit.AC3.6ch].mkv
The ":" would then be validated to be removed and the naming would be:
Formula 1 Drive to Survive\Formula 1 Drive to Survive - s01e01 - All to Play For [WEB-DL.1080p.x264.8Bit.AC3.6ch].mkv

My Filebot naming is:

Code: Select all

{primaryTitle.ascii().replace(':','')}/{plex[2]}/{n} - {episode.special ? 's00e'+special.pad(2) : s00e00.lower()} - {t.replaceAll(/[`´‘’?]/, /'/).replaceAll(/[!?.]+$/).replacePart(', Part $1')} [{any{fn =~ /WEB.RIP|WEBRip|WEBDL|WEB.DL|WEB|web/ ? /WEB-DL/ : null}{source}{'WEB-DL'}}{'.'+VF}{'.'+VC}{'.'+BITDEPTH+'Bit'}{'.'+AC}{'.'+AF}]{'.'+lang}
I might be overcomplicating this? - Maybee its just enough to replace ":" with a space and a - like this " -" how would I go about that for the directory name and the file naming? (Really close getting them aligned to do the same :) )

Best regards
Casperse
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Filebot = Sonarr naming scheme

Post by rednoah »

How does Sonarr deal with colon : in series name?

The usual approach is to just replace : with - and at least as far as FileBot and Plex is concerned, that's both fine:

Code: Select all

n.colon(/ - /)
:idea: Please read the FAQ and How to Request Help.
casperse
Posts: 29
Joined: 19 Aug 2017, 09:17

Re: Filebot = Sonarr naming scheme

Post by casperse »

rednoah wrote: 18 Mar 2019, 12:19 How does Sonarr deal with colon : in series name?

The usual approach is to just replace : with - and at least as far as FileBot and Plex is concerned, that's both fine:

Code: Select all

n.colon(/ - /)
By trial and error it looks like its replacing ":" with space and - ---> " -" :

Formula 1: Drive to Survive\Formula 1: Drive to Survive - s01e01 - All to Play For [WEB-DL.1080p.x264.8Bit.AC3.6ch].mkv -->
Formula 1 - Drive to Survive\Formula 1 - Drive to Survive - s01e01 - All to Play For [WEB-DL.1080p.x264.8Bit.AC3.6ch].mkv

How would I combine this?

Directory replacement:
{n.replace(':',' -')}{plex[1]}/
{n.colon(' - '){plex[1]}/

Filename replacement: can I add the {n.replace(':',' -')} or {n.colon(' - ') to below string?
I already have a replaceAll

Code: Select all

{n} - {episode.special ? 's00e'+special.pad(2) : s00e00.lower()} - {t.replaceAll(/[`´‘’?]/, /'/).replaceAll(/[!?.]+$/).replacePart(', Part $1')} [{any{fn =~ /WEB.RIP|WEBRip|WEBDL|WEB.DL|WEB|web/ ? /WEB-DL/ : null}{source}{'WEB-DL'}}{'.'+VF}{'.'+VC}{'.'+BITDEPTH+'Bit'}{'.'+AC}{'.'+AF}]{'.'+lang}
BTW: I have always used the {primaryTitle.ascii().replace(':','')} because my metadata was using IMDB but now everything have changed and everyone is using TVDB/themoviedb as the standard is it correct that filebot does the same by using "plex[1]" instead of "primaryTitle" would make this change easy for me?

Again thanks for you help! I am using the paid version on my windows 10, but my naming string seem to have grown beyond my understanding
casperse
Posts: 29
Joined: 19 Aug 2017, 09:17

Re: Filebot = Sonarr naming scheme

Post by casperse »

Deleted - Im stupid....
Last edited by casperse on 18 Mar 2019, 14:52, edited 1 time in total.
casperse
Posts: 29
Joined: 19 Aug 2017, 09:17

Re: Filebot = Sonarr naming scheme

Post by casperse »

Forget it I made another error I think this is a 1:1 for Sonarr

Code: Select all

{n.replaceAll(/[:|]/, " - ")}/{plex[2]}/{n.colon(/ - /)} - {episode.special ? 's00e'+special.pad(2) : s00e00.lower()} - {t.replaceAll(/[`´‘’?]/, /'/).replaceAll(/[!?.]+$/).replacePart(', Part $1')} [{any{fn =~ /WEB.RIP|WEBRip|WEBDL|WEB.DL|WEB|web/ ? /WEB-DL/ : null}{source}{'WEB-DL'}}{'.'+VF}{'.'+VC}{'.'+BITDEPTH+'Bit'}{'.'+AC}{'.'+AF}]{'.'+lang}
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Filebot = Sonarr naming scheme

Post by rednoah »

:idea: Please read the FAQ and How to Request Help.
Post Reply