Help with a simple command

Running FileBot from the console, Groovy scripting, shell scripts, etc
Post Reply
gavdari
Posts: 8
Joined: 11 Mar 2013, 21:56

Help with a simple command

Post by gavdari »

Hey guys,
I'm trying to add a simple command to Windows context menu so when I right click on a newly downloaded episode and click on "Organize", it would find the subtitles, rename the file and move the file and the subtitle to the correct location. Here's the command I'm running for "Organize Movie":

Code: Select all

filebot -get-missing-subtitles "%~f1" --lang en 
filebot -rename -non-strict "%~f1" --db IMDb --lang en --format "H:/Films/{n}"
move "%~n1.eng.srt" "H:/Films/"
move "%~n1.eng.ssa" "H:/Films/"
"C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Scanner.exe" --scan --refresh --section 16
This one works fine. The problem is with the TV command:

Code: Select all

filebot -rename -non-strict "%~f1" --db tvdb --lang en --format "H:/TV Series/{n}/Season {s}/{n} - {s00e00} - {t}"
filebot -get-missing-subtitles "%~f1" --lang en -non-strict
"C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Scanner.exe" --scan --refresh --section 15
The problem is I can't move the subtitles the same way, because the destination of each subtitle differs from the other one in the case of TV episodes. Is there any way (in the second command) to move the subtitle to the same location as the file itself?

On another note, is it possible to show a message when something was not found? like TV name and info or some subtitles?
User avatar
rednoah
The Source
Posts: 23930
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Help with a simple command

Post by rednoah »

Yes, but you need to pass in both the video file and the subtitle file in the -rename call if you want both files in the same input set.
:idea: Please read the FAQ and How to Request Help.
Post Reply