Filebot MyJdownloader AMC Plex Script

Running FileBot from the console, Groovy scripting, shell scripts, etc
Post Reply
missaq
Posts: 10
Joined: 22 Oct 2019, 07:42

Filebot MyJdownloader AMC Plex Script

Post by missaq »

Dear community could you please look at my Script and tell me if it is right?
I am not sure if i do to much. For example do i have split SERIEN, FILME and move them separately or will the amc do this for me automatically?
It would be nice if you could help me to improve my script.

Code: Select all

#!/bin/sh
export JAVA_OPTS="-Xmx512M"
##FileBot benätigt diese Variablen
LOG="/volume1/Mediathek/Logs/amc.log"
EXC="/volume1/Mediathek/Logs/amc.txt"
FILME="/volume1/Mediathek/{plex}"
SERIEN="/volume1/Mediathek/{plex}"
### Wenn Filebot mal etwas nicht zuordnen kann, dann kannst du es in einen seperaten Ordner verschieben lassen, dann bleibt es im Downloadordner Übersichtlich.
UNSORTIERT="/volume1/Mediathek/Downloads/Unsortiert/{file.structurePathTail}"
##FileBot ausführen
/var/packages/filebot/target/filebot.sh -script fn:amc --def skipExtract=y --lang de --log-file $LOG --action move "$1" --def "seriesFormat=$SERIEN" "movieFormat=$FILME" "unsortedFormat=$UNSORTIERT" -non-strict --def unsorted=y --def clean=y
## Aufräumen, --def root löscht den Unterordner mit
/var/packages/filebot/target/filebot.sh -script fn:cleaner "$1" --def root=y
User avatar
rednoah
The Source
Posts: 22975
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Filebot MyJdownloader AMC Plex Script

Post by rednoah »

1.
The amc script can generally differentiate between series and movie files, though if you somehow know which is which in advance, that passing that information in would be best. Please read the amc script manual for details.


2.
I recommend using #!/bin/sh -xu as shebang to make sure you're getting nice error messages if you accidentally end up using shell variables that are not defined, and generally see what's happening step by step.
:idea: Please read the FAQ and How to Request Help.
missaq
Posts: 10
Joined: 22 Oct 2019, 07:42

Re: Filebot MyJdownloader AMC Plex Script

Post by missaq »

Hi rednoah,

I have just updated filebot to version 4.9.0 and Java to 2.13. Now nothing works no file rename and no move, with the script above.
I have also no logs, nothing. Script is still the same.

Update:

I have restarted my Nas and now I get this log

Code: Select all

Current application revision (r7234) does not match cache revision (r6810): reset cache
Initialize new disk cache: /var/packages/filebot/target/data/root/cache/0
Run script [fn:amc] at [Thu Mar 19 15:15:36 CET 2020]
Parameter: skipExtract = y
Parameter: seriesFormat = /volume1/Mediathek/{plex}
Parameter: movieFormat = /volume1/Mediathek/{plex}
Parameter: unsortedFormat = /volume1/Mediathek/Downloads/Unsorted/{file.structurePathTail}
Parameter: unsorted = y
Parameter: clean = y
Argument[0]: /volume1/Mediathek/Downloads/72BD-DieSchoeneunddasBiestTHEATRICAL-LizardSquad/Die.Schoene.und.das.Biest.1991.THEATRiCAL.German.720p.BluRay.x264-LizardSquad/Proof
Activate License [PX7894368] on [Thu Mar 19 15:15:37 CET 2020]
No files selected for processing
Done ¯\_(ツ)_/¯
Best Regards
User avatar
rednoah
The Source
Posts: 22975
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Filebot MyJdownloader AMC Plex Script

Post by rednoah »

The log shows no error. Presumably, your Argument[0] input folder doesn't exist, doesn't contain any files, appears to not contain any files due to permissions, etc.


:idea: Most likely completely unrelated to upgrading FileBot or Java.
:idea: Please read the FAQ and How to Request Help.
Post Reply