Overwriting Extension with Script

Running FileBot from the console, Groovy scripting, shell scripts, etc
Post Reply
JackDownAHill
Posts: 2
Joined: 24 May 2015, 05:53

Overwriting Extension with Script

Post by JackDownAHill »

Hello there,

I'm looking for help with two things;
First one being, I'm looking for a way to change the extensions of the files I process while using the script. Like the 'Override extension' option in the GUI.

I have this set up as a batch file, which I run with Deluge in order to sort my files,

Code: Select all

D:\Programs\FileBot\filebot.exe -script fn:amc --output "F:/Downloads/Renamed" --log-file amc.log --action copy -non-strict --def minFileSize=10 clean=y artwork=n extras=n music=y unsorted=y "ut_kind=multi" "ut_dir=F:/Downloads/Renamed/Unsorted" "seriesFormat=B:/New TV Shows/Check/{n}/{'Season '+s}/{n} - {sxe} - {t}" "animeFormat=Z:/Anime/New Downloads/Check/{n}/{'Season '+s}/{n} - {sxe} - {t} - [{group} - {vf}]" "movieFormat=B:/New Movies/Check/{n} ({y})"
Everything works great, however I would like to be able to have them all converted to .mkv file extensions. So when I go to replace them with better quality versions, I don't end up with two files because one was an mp4 and the other an avi.


The second one is a bit simpler. Regarding the code,

Code: Select all

--filter "age < 7" --def "ut_label=TV"
If I want to have it filter everything but movies (both anime and TV series), how do I go about doing that?
Also, I'm unsure where to put it into my existing code for it to function properly.


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

Re: Overwriting Extension with Script

Post by rednoah »

1)
The amc script can't do that. There is no "Extension: Override" equivalent in the cmdline tools.

2)
That's not possible. You can force exactly 1 mode only. And especially when dealing with Anime and TV Shows you absolutely want to force one or the other since telling the difference can be very tricky in many cases.

3)
You do understand what --def excludeList does and you have decided not to use it for a very good reason, right?
:idea: Please read the FAQ and How to Request Help.
JackDownAHill
Posts: 2
Joined: 24 May 2015, 05:53

Re: Overwriting Extension with Script

Post by JackDownAHill »

Thanks for the reply.

1- Ok

2 - So I can force either Anime, TV or Movies? Or force it on all of them or non of them? Because the issue I'm having is with some of the newer anime series having names almost identical to other seasons ("Fate stay night", "Fate stay night [Unlimited Blade Works] (2014)" and "Fate stay night [Unlimited Blade Works] (2015)"). It always wants to do the shortest naming scheme and it aired ages ago.

3 - Yes I do. This is the second stage of my sorting. I've got a batch file that runs before this one that runs strict and is connected to my completed downloads folder. I had the exclude list connected to both stages at first, but it caused the second stage to skip files, ending up with a lot of unchanged files in my manual sort folder.

Here is the code for the first stage,

Code: Select all

D:\Programs\FileBot\filebot.exe -script fn:amc --output "F:/Downloads/Renamed" --log-file amc.log --action move --def excludeList=amc.txt minFileSize=1 clean=y artwork=n extras=n music=y unsorted=y "ut_kind=multi" "ut_dir=F:/Downloads/Completed" "seriesFormat=B:/New TV Shows/{n}/{'Season '+s}/{n} - {sxe} - {t}" "animeFormat=Z:/Anime/New Downloads/{n}/{'Season '+s}/{n} - {sxe} - {t} - [{group} - {vf}]" "movieFormat=B:/New Movies/{n} ({y})"

"F:/Downloads/Autosort Check.bat"

exit
'Autosort Check.bat' is the first lot of code I posted.

The process is as follows "Strict>non-strict>manual", each being moved to their own location as to not be scanned more then once each stage.
User avatar
rednoah
The Source
Posts: 23953
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Overwriting Extension with Script

Post by rednoah »

2) If you find mismatches paste the path/file names here in the forums so I can try it myself and see if it can be fixed. That depends on the exact case.

You can always use --filter to tweak things though and if you're using age < 7 it can't really go wrong there. Unless all these shows that are named the same are also aired at the same time, but that doesn't happen.
:idea: Please read the FAQ and How to Request Help.
Post Reply