Page 1 of 1

Running Filebot with custom lang and format & seasonlist

Posted: 30 Nov 2015, 18:07
by zaunfink
Hello!

I'm in the middle of a round of emby-fuelled reordering of my media (seriously, no love for S01?) and this has led me to the following "problem":

Assuming for a moment that one lives in Germany, but has a deep love for watching things in english (mostly because one has no patience and syncs can be slow). Assume ones family does not share this love, leading to two collections - one for oneself with everything in english and one with files renamed with german titles.

Most sorting for my files happens immediately after download via triggering of a batch file and the rest is sorted by hand due to much smaller volume.
Said reordering is leading to fairly big quantities of seasons though, which have to be manually added and I'm starting to get annoyed by the frequent switching.

Then I saw the post about FreeCommander-Buttons (http://www.filebot.net/forums/viewtopic.php?t=2986) but I can't get it to play nice with --lang and --format.


Preferably I'd end up with a row of buttons for several use-cases, since I have active seasons on a different disk for travels, which ends up being 6 different configurations and that sucks. (And yes, I am aware that processing repeatedly is a crap idea and ideally, Kodi&Friends should be used for sorting and looking at stuff, but my setup doesn't allow that. I need my current stuff ready and well-sorted for kodiless half-day train travels :()

So, is it possible to load the filebot GUI with a pre-set language and a pre-set format?



That actually kinda leads me to problem 2, which popped up during the writing of this slightly rambling post:

There's an {episodelist} binding. It IS possible to misuse this to detect the currently running season, but is there a binding that will spit out the current/max season on it's own?


Thanks!

Re: Running Filebot with custom lang and format & seasonlist

Posted: 30 Nov 2015, 19:08
by rednoah
1.
FileBot 4.6.1 supports Presets and you can preset Language and Format, among other things. So you could have a preset called "Family Movies" which processes files using TheMovieDB in German using some specific Format.

I'd probably have my own stash that I manage myself with the GUI, and use the amc script to "mirror" things for other people (make sure to use --action hardlink and --def excludeList) automatically once in a while.

2.
Nope, you'll have to (mis)use {episodelist} if you need to come up with strange not-episode-specific information.

Code: Select all

{episodelist.season.max()}
PS: It's a bad idea to have a folder structure that changes over time.

Re: Running Filebot with custom lang and format & seasonlist

Posted: 30 Nov 2015, 23:13
by zaunfink
It does? It does! That's awesome timing! (Also, that's what I get for not reading release notes...).
Just tried it, it's awesome! Thank you!

Can I call those via the command line?

Yeah, I just stash the stuff we both watch on my moms drive and feed it into emby/kodi via the network, we don't really have that much of the same shows/movies.
Never got around to setting up the amc for her, mostly because she watches stuff that comes in mislabeled and I have to manually fix season and episode numbers sometimes. Just not worth the hassle, seeing how she normally gets season packs.

My setup runs completely automated otherwise, things simply pop up in kodi :D The amc script is really awesome.
It'd be annoying to have to go and remember what shows runs on which day, so I run flexget for that on a headless box, grab the files via a sync app and that calls filebot on my laptop after the sync is through.

And for 2: Tried it, works like a charm (of course it does). Thank you! Full seasons with all episodes go on the big drive, seasons in progress go on the small one. Yay!

P.S.: But but but it's really just a little bit and I promise I don't even have to reprocess anything! I swear!
(I replace my english files once they are released in DL, so I just delete most things and what I have to catch up on just gets moved/copied to the proper folder)

Re: Running Filebot with custom lang and format & seasonlist

Posted: 30 Nov 2015, 23:35
by rednoah
1.
Can I call those via the command line?
You can make your own "presets" with alias or *.sh files. :D

e.g.
https://github.com/filebot/plugins/blob ... ash/amc.sh


2.
You might wanna use {info.status} for that.

Re: Running Filebot with custom lang and format & seasonlist

Posted: 01 Dec 2015, 00:29
by zaunfink
1. Someday I'll have everything automated! :D

2. I use that too, since I stuff my shows in the cloud (space limits :/) and it's useful to know which folders I need to check for german releases periodically. Ideally I'd drop that, but it's easier this way than having to google my way through all my shows. Those in "Finished" are done and shall only be touched for pleasure.

The season part is simply to sort the currently releasing season, because there's no point in syncing english files into the cloud, since I'd just have to delete them later (usually, because sometimes I do get shows just in english, so I can't go by language).



With my newly gained knowledge I now run this for my shows (Originally bastardized from ithiel's script, I really need to check for improvements)

Code: Select all

{norm={it.replaceAll(/[\'*?]+/).replaceAll(/[:|]/, ' - ').replaceAll(/\b[IiVvXx]+\b/, { it.upper() })};norm('')}{episodelist.season.max() == s && !model.episode.containsAll(episodelist.findAll{it.season == s}) ? 'P:/Mine/Watching' : 'K:/Hubicify/'+(info.status == 'Continuing' ? 'Continuing_Incomplete' : 'Finish_ed')+'/'+norm(ny)}/{n.replaceTrailingBrackets() =~ / / ? norm(n.acronym()) : norm(n)}{episode.special ? ' Specials' : ' Season '+s.pad(2)} [{la = any{audios.language == [de,en] ? 'DL' : media.Audio_Language_List}{file.path.match(/\W(DL)/)}{file.path.findMatch(/\W(German)/) ? 'DE':'EN'}}]/{norm(n)} {episode.special ? 'S00E'+special.pad(2) : s00e00} - {norm(t).replacePart(' Part $1 ')} {' ['+la+']'}{tags}[{allOf{ac}{vf.match(/720[pP]|1080[pP]/)}{source}{vc} join ']['}]{def g = c{group}; def m = c{fn.match(/(?:(?<=[-])[a-z0-9]+$)|(?:^[a-z0-9]+(?=[-]))/)}; if(g==null && m!=null) return '['+m+']'; if(g!=null && m!=null && m.lower()!=g.lower()) return '['+m+']'; if(g!=null) return '['+g+']';}
Basically: Set up normalizing for names (I'm sure there's a better way than running it on an empty string, but it's late and I just want it to work for now),
-check if it's a single episode from the current season, if yes, put it on travel drive in season folder
-if no, put into cloud folder with full structure

Structure is

Code: Select all

Show (Year)/Acronym if word > 1 Season 00 [Lang tag]/Show S00E00 - Episode [Lang and other tags][Group in complicated because german groups suck]