Page 1 of 1

Add [Ended] to show name

Posted: 27 Feb 2014, 11:49
by Zerelah
Hi
I would like to Add Ended to the show name if the show is now longer running I have browsed the forum and found this

Code: Select all

{episodelist.season.max()}
But i dont know how to use it. :?
In double episodes how can i change
S01E01-E02 to S01E01E02

This is my tv string

Code: Select all

{n.replaceAll(/[.:;_]/, " ") + ']'}/{episode.special ? 'Season 0' : 'Season '+s}/{csv('D:/filebot/names.csv').get(n) ?: n} - {episode.special ? 'S00E'+special.pad(2) : s00e00} - {t}{"."+lang.getDisplayName(Locale.getDefault()).upperInitial()}
I have been working on this a long time since I dont really dont what im doing hope someone will tell me if it will remove illigal char.
my movie string

Code: Select all

D:/Utorrent/!MOVIES/{n.sortName()[0].match((~/(?i)[0-9]/):'0-9',(~/(?i)[a-d]/):'ABCD',(~/(?i)[e-h]/):'EFGH',(~/(?i)[i-l]/):'IJKL',(~/(?i)[m-p]/):'MNOP',(~/(?i)[q-t]/):'QRST') ?: 'UVWYXZ'}/{n.replaceFirst(/^(?i)(The|A|An)\s(.+)/, /$2, $1/)} ({y}){' [' + file.path.matchAll(/extended|uncensored|remastered|unrated|uncut|3d|director.*cut|special.edition/)*.upperInitial()*.lowerTrail().sort().unique().join(', ').replaceAll(/[._]/, " ") + ']'} /{n.replaceAll(/[._]/," ")} ({y}) {"CD$pi"}{' [' + file.path.matchAll(/extended|uncensored|remastered|unrated|uncut|3d|director.*cut|special.edition/)*.upperInitial()*.lowerTrail().sort().unique().join(', ').replaceAll(/[._]/, " ") + ']'} {[c{source} ?: 'BDrip']}{"."+lang.getDisplayName(Locale.getDefault()).upperInitial()}
Thanks

Re: Add [Ended] to show name

Posted: 27 Feb 2014, 14:11
by rednoah
I think you can get that with

Code: Select all

{info.status}
If you don't want to use {s00e00} then you have to do the whole logic yourself with {s} and {es}.

Re: Add [Ended] to show name

Posted: 27 Feb 2014, 15:14
by Zerelah
Hi
how would i use {info.status} to get Ended.
I have made my string almost entirely of cut and paste. and i do wanna use the s00e00 format but i wanna get rid of - in S04E02-E03

Re: Add [Ended] to show name

Posted: 27 Feb 2014, 19:19
by rednoah
1. Try it. Pretty sure the value of info.status is "Ended" if the show has ended, some other value otherwise. You have the data, the logic how to use it is up to you. This is basic, plenty of examples here.

2. s00e00.replace('-', '')

Re: Add [Ended] to show name

Posted: 27 Feb 2014, 21:05
by Zerelah
Hey rednoah
you are right it works but it list continuing also how would i get rid of that. ?
If I us .replace(continuing) it removes the ended too
been looking around and decided to try this

Code: Select all

 {if(info.status =="Ended") then "Ended" else "?"}
but i can find anywhere how to nothing/ignore

{[info.status.match(/Ended/)]}
Succes :D

Merci

Re: Add [Ended] to show name

Posted: 28 Feb 2014, 15:33
by rednoah
Yep, the last one is how I would have done it. ;)