SHARE
TWEET
Untitled
a guest
Mar 27th, 2018
107
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- #!/bin/bash
- torrentid=$1
- torrentname=$2
- torrentpath=$3
- x=1
- while [ $x -le 100 ]
- do
- sleep 2
- echo "Running $x times" >> ~/script.log
- echo "TorrentID: $torrentid" >> ~/script.log
- line=$(deluge-console "connect 127.0.0.1:52679; info" $1 | grep "Tracker status")
- echo $line >> ~/script.log
- case "$line" in
- *unregistered*|*Sent*|*End*of*file*|*Bad*Gateway*|torrentleech.org*Error*Connection*Timed*Out*|*Connection*Time*Out*|Error*Connection*Timed*Out*|Tracker status:*torrentleech.org*Error*Connection*Timed*Out*)
- deluge-console "connect 127.0.0.1:52679; pause '$torrentid'"
- sleep 3
- deluge-console "connect 127.0.0.1:52679; resume '$torrentid'"
- ;;
- *)
- echo "Found working torrent: $torrentname $torrentpath $torrentid" >> ~/script.log
- exit 1;;
- esac
- x=$(( $x + 1 ))
- done
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy.

