Page 1 of 1
Set up AMC script with Deluge
Posted: 28 Aug 2017, 17:02
by hussain2407
Hi every one,
I need help with code or script for moving my finished download for both movies and tvshows.
im using rasperry pi as downloading server + sonarr and radarr for my downloads, but i have alots of problems in moving the finished files.
I used to have FileBot long time ago on windows and it was perfect and 0 issue. but since i moved to linux/raspberry and im not able to set it correctly.
i need and very simple code that move, rename and search for arabic subtitles if available.
My setup:
I use Deluge as download clinet.
I download the files locally in reaspberry first, then i move them to mounted shared network folder.
the folder structure is:
Shared name: share. path= /media/share
then i have three folders:
1- Movies
2-TVshows
3- Animation
appreciate your help
thanks and regards
Re: Need Help for code/script
Posted: 29 Aug 2017, 13:09
by rednoah
Have you tried the amc script yet?
Re: Need Help for code/script
Posted: 30 Aug 2017, 18:45
by hussain2407
yes, I used to have amc in my utorrent client for the finished downloads on windows machine, now I'm using deluge on raspberry pi3.
any recommended setup for my finished download for both movies and show
thank you
Re: Need Help for code/script
Posted: 30 Aug 2017, 23:43
by rednoah
Here are the setup instructions for the amc script with deluge:
viewtopic.php?f=4&t=215#p3382
Re: Set up AMC script with Deluge
Posted: 31 Aug 2017, 16:54
by hussain2407
when I run the fn:amc ... it show onl the Input and the file name .. and no more action ..
this is the output:
/opt/share/filebot/filebot.sh -script fn:amc "/home/pi/completed" --action copy --output "/home/pi/media" -non-strict
Run script [fn:amc] at [Thu Aug 31 16:31:24 UTC 2017]
Argument[0]: /home/pi/completed
Ignore orphaned subtitles: /home/pi/completed/It.Comes.at.Night.2017.1080p.WEB-DL.DD5.1.H264-FGT/English.srt
Input: /home/pi/completed/Game.of.Thrones.S07E01.HDTV.x264-SVA[rarbg]/Game.of.Thrones.S07E01.HDTV.x264-SVA.mkv
Input: /home/pi/completed/It.Comes.at.Night.2017.1080p.WEB-DL.DD5.1.H264-FGT/It.Comes.at.Night.2017.1080p.WEB-DL.DD5.1.H264-FGT.mkv
Input: /home/pi/completed/Narcos.S01E01.1080p.WEBRip.x264-2HD[rarbg]/narcos.s01e01.1080p.webrip.x264-2hd.mkv
Input: /home/pi/completed/Narcos.S01E03.720p.WEBRip.x264-TASTETV[rarbg]/Narcos.S01E03.720p.WEBRip.x264-TASTETV.mkv
NOTHING MORE?
please advice
Re: Set up AMC script with Deluge
Posted: 01 Sep 2017, 01:02
by rednoah
That is indeed strange. The script itself couldn't hang there. How long does it hang there? Does the process continue to use CPU and memory?
Maybe an underlying filesystem operation is blocking the process? Or you're running out of memory? If something doesn't work, I'd expect an error message after a while though.
Re: Set up AMC script with Deluge
Posted: 01 Sep 2017, 17:28
by hussain2407
it is working but it takes very long time... after an hour only tow files were processed!!
I will rerun it again and see.
Re: Set up AMC script with Deluge
Posted: 01 Sep 2017, 17:46
by hussain2407
it is in
Auto-detected query: [Narcos]
for more than 20 minutes
Re: Set up AMC script with Deluge
Posted: 01 Sep 2017, 17:56
by rednoah
Please run filebot -script fn:sysinfo and post the output.
Re: Set up AMC script with Deluge
Posted: 01 Sep 2017, 18:10
by hussain2407
here is the output:
Code: Select all
pi@RP3:~/media/TV $ /opt/share/filebot/filebot.sh -script fn:sysinfo
FileBot 4.7.7 (r4678)
JNA Native: 4.0.0
MediaInfo: 0.7.70
Apache Commons VFS: [zip, rar]
Chromaprint: java.io.IOException: Cannot run program "fpcalc": error=2, No such file or directory
Extended Attributes: OK
Unicode Filesystem: OK
Script Bundle: 2017-05-15 (r500)
Groovy: 2.4.7
JRE: OpenJDK Runtime Environment 1.8.0_131
JVM: 32-bit OpenJDK Zero VM
CPU/MEM: 4 Core / 224 MB Max Memory / 13 MB Used Memory
OS: Linux (arm)
Package: IPKG
uname: Linux RP3 4.9.35-v7+ #1014 SMP Fri Jun 30 14:47:43 BST 2017 armv7l GNU/Linux
------------------- UPDATE AVAILABLE: FileBot 4.7.9 (r4984) --------------------
Done ヾ(@⌒ー⌒@)ノ
Re: Set up AMC script with Deluge
Posted: 02 Sep 2017, 01:00
by rednoah
1.
You're using an outdated version of FileBot.
Please use the latest version of FileBot.
2.
You're using the
Zero VM where zero stands for zero JIT optimizations.
Please use the latest Oracle JDK.
3.
224 MB is probably enough, but may not be depending on what you're doing. I recommend doing something like
-Xmx512m to give Java / FileBot more memory.
Re: Set up AMC script with Deluge
Posted: 03 Sep 2017, 01:56
by hussain2407
hi
it is working now after going to the latest Filebot and updating the JDK,
but this time I have installed the filebot instead for using the portable,
and one more thing can I get your help with my code, so far the one I'm testing is a script and I don't know how I change it to deluge command, under the perferences - Execute I have added the script location but nothings happening?
Code: Select all
#!/bin/sh
DATE_STAMP=` date +%d-%m-%Y-%T`
echo ${DATE_STAMP}
FILEBOT="filebot"
SCRIPT="-script fn:amc"
LANG="--lang ar"
DESTINATION="/home/pi/media/"
COMPLETED="/home/pi/completed/"
ACTION="--action copy"
CONFLICT="--conflict skip"
DEF="--def reportError=y music=y artwork=y subtitles=en,ar clean=y"
SUBTITLES="--def subtitles=en,ar"
PUSHBULLET="--def pushbullet=XXXXXXXXXXXXXXXXX"
KODI="--def kodi=10.10.10.4:8080"
#CLEAN="--def clean=y"
LOG="amc.log"
"$FILEBOT" $SCRIPT $LANG $ACTION $CONFLICT -non-strict --output "$DESTINATION" ${DEF} $PUSHBULLET $SUBTITLES "seriesFormat=/home/pi/media/TV/{n}/{'Season '+s}/{n} - {s00e00} - {t} - {vf}.{vc}.{ac}" "movieFormat=/home/pi/media/Movie/{n} {y}/{fn}" "$COMPLETED" $KODI --log ALL
DATE_STAMP=` date +%d-%m-%Y-%T`
echo ${DATE_STAMP}
I want to run this after the download finish with label sorting to Movies and TVshows folders
can you please advice
thanks