detecting multi episodes?!?!

Any questions? Need some help?
Post Reply
blacksabbath247
Posts: 3
Joined: 11 Sep 2019, 15:23

detecting multi episodes?!?!

Post by blacksabbath247 » 11 Sep 2019, 16:16

Gonna try to make this short. Basically my shows from before I used plex are formatted in a way that filebot cant completely detect when Multi episode files come into play, also my Animanics download which seems named pretty clean also cant be detected as multi episodes. I really dont wanna ask to be spoon fed here but am pretty tired of tryna figure out why my filebot wont match up the names. I am truly at my wits end and will need more time to learn Groovy code as I am not familiar with coding.

-The format my Animaniacs came in - "Animaniacs - S01E01 - De-Zanitized. The Monkey Song & Nighty-Night Toon.avi"

-My format for Ed Edd n Eddy - "8 - Fool on the Ed ~ A Boy And His Ed"

-Really need my shows to be in this format "The Berenstain Bears - S04E17-E18 - Bears For All Seasons, Grow It" so my plex can detect it

1.This Pre-proccess code ALMOST solves my problem as it detecs about half of the epsiodes and names them correctly - {episodelist.findAll{ fn =~ it.title }.join(' & ')}

2. This code was given to me by another user on another website and was said to to be used for his Multi Episode needs.I believe the "~" used in my format stops the code from detecting my episodes. I really dont know why it doesnt work for animaniacs
{n}
- {episode.special ? "00x"+special.pad(2) : s.pad(2)+"x"+episodes*.episode*.pad(2).join("-"+s.pad(2)+"x")}
- {t}

User avatar
rednoah
The Source
Posts: 16821
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: detecting multi episodes?!?!

Post by rednoah » 11 Sep 2019, 17:45

Let's look at auto-detection and formatting separately.


1.
Multi-Episode detection based on episode titles is not supported.

This pre-processing step simply relies on checking the file name against each episode title in the format to come up with a new file name:

Code: Select all

{episodelist.findAll{ fn =~ it.title }.join(' & ')}
:idea: Notably, this format completely ignores anything that FileBot auto-detection may have come up with (except for the series, which is used for episodelist). It's a hack.


2.
Assuming that FileBot has correctly auto-detected a multi-episode, bindings such as {sxe} or {s00e00} or {plex} will work correctly out of the box.

e.g.

Code: Select all

X:/Media/{plex}
:idea: Please read the FAQ and How to Request Help.

kim
Power User
Posts: 810
Joined: 15 May 2014, 16:17

Re: detecting multi episodes?!?!

Post by kim » 11 Sep 2019, 19:57

it looks like your files are made so Multi-Episode <=> same airdate...
so maybe you can use the airdate from e.g. episodelist

e.g. Animaniacs - S01E01 - De-Zanitized. The Monkey Song & Nighty-Night Toon
S01E01 = 'same date' then find all with 'same date'

kim
Power User
Posts: 810
Joined: 15 May 2014, 16:17

Re: detecting multi episodes?!?!

Post by kim » 11 Sep 2019, 20:14

something like this

Code: Select all

{n}{' - S' + s.pad(2) + episodelist.findAll{ airdate == it.airdate }.collect{'E' + it.episode.pad(2) }.join('-') + ' - ' + episodelist.findAll{ airdate == it.airdate }.collect{it.title }.join(' & ') }
output:
Animaniacs - S01E01-E02-E03 - De-Zanitized & The Monkey Song & Nighty-Night Toon

kim
Power User
Posts: 810
Joined: 15 May 2014, 16:17

Re: detecting multi episodes?!?!

Post by kim » 11 Sep 2019, 22:52

or version 2:

Code: Select all

{n}{def fileSet = episodelist.findAll{ airdate == it.airdate }; ' - S' + s.pad(2) + 'E' + fileSet.episode.min().pad(2) + '-E' + fileSet.episode.max().pad(2) + ' - ' + fileSet.title.join(' & ') }
Animaniacs - S01E01-E03 - De-Zanitized & The Monkey Song & Nighty-Night Toon

blacksabbath247
Posts: 3
Joined: 11 Sep 2019, 15:23

Re: detecting multi episodes?!?!

Post by blacksabbath247 » 12 Sep 2019, 07:37

kim wrote:
11 Sep 2019, 22:52
or version 2:

Code: Select all

{n}{def fileSet = episodelist.findAll{ airdate == it.airdate }; ' - S' + s.pad(2) + 'E' + fileSet.episode.min().pad(2) + '-E' + fileSet.episode.max().pad(2) + ' - ' + fileSet.title.join(' & ') }
Animaniacs - S01E01-E03 - De-Zanitized & The Monkey Song & Nighty-Night Toon
Awesome let me try the code out and ill get back to you, was busy today... Thanks alot for taking the time to help, I really appreciate it guys. Im really excited to try this new code out!!!

blacksabbath247
Posts: 3
Joined: 11 Sep 2019, 15:23

Re: detecting multi episodes?!?!

Post by blacksabbath247 » 05 Oct 2019, 06:14

kim wrote:
11 Sep 2019, 22:52
or version 2:

Code: Select all

{n}{def fileSet = episodelist.findAll{ airdate == it.airdate }; ' - S' + s.pad(2) + 'E' + fileSet.episode.min().pad(2) + '-E' + fileSet.episode.max().pad(2) + ' - ' + fileSet.title.join(' & ') }
Animaniacs - S01E01-E03 - De-Zanitized & The Monkey Song & Nighty-Night Toon
Oh my gosh sorry it took so long too get back to you!!! I have been SUCCESSFULLY renaming my multi episode cartoons with the code you gave me. Shows such as Ed Edd n Eddy, The Marvelous MisAdventures ofFlapjack, Chalkzone,El Tigre The Adventures of Manny Rivera, Johnny Bravo, My Gym Partners a Monkey, Rugrats and Rocket Power!!! I can never thank you enough oh my gosh you are a lifesaver by all means. Its safe to say this thread has been SOLVED thank you so much.

ATTENTION!!!The code given by Kim detects episodes by AIRDATE Animaniacs and Chowder have episodes that are very spearted in that regards. Basically for certain series some episodes will have to be renamed manually such at the mentioned due to airdates not being perfect. Simply reanme those epsiodes manually.

This code is the one that worked FLAWLESSLY

Code: Select all

{n}{def fileSet = episodelist.findAll{ airdate == it.airdate }; ' - S' + s.pad(2) + 'E' + fileSet.episode.min().pad(2) + '-E' + fileSet.episode.max().pad(2) + ' - ' + fileSet.title.join(' & ') }

Post Reply