diff --git a/offload-wolfpack b/offload-wolfpack index 0183d3a..298575d 100755 --- a/offload-wolfpack +++ b/offload-wolfpack @@ -6,9 +6,9 @@ if [ "$(pgrep -afc wolfpack)" -ne 1 ]; then fi /usr/local/bin/wolfpack --alpha sleep 10 -rsync -avz /srv/yggdrasil/new_acquisition/* cxford@10.0.1.3:/srv/yggdrasil/new_acquisition &>>/var/log/wolfpack.log -ls -l /srv/yggdrasil/new_acquisition >> /var/log/wolfpack.log -echo Files transferred from $(uname -n). >> /var/log/wolfpack.log +rsync -avz /srv/yggdrasil/new_acquisition/* cxford@10.0.1.3:/srv/yggdrasil/new_acquisition 2>&1 | tee -a /var/log/wolfpack.log +ls -l /srv/yggdrasil/new_acquisition | tee -a /var/log/wolfpack.log +echo Files transferred from $(uname -n). | tee -a /var/log/wolfpack.log rm -Rf /srv/yggdrasil/new_acquisition/* cat /var/log/wolfpack.log | ssh cxford@aninix.net "cat >> /var/log/wolfpack.log" rm /var/log/wolfpack.log diff --git a/wolfpack b/wolfpack index 586d63a..bd3b91c 100755 --- a/wolfpack +++ b/wolfpack @@ -57,7 +57,7 @@ function nextairdate { echo "Need a show to search for" exit 1; fi - lynx --dump "https://www.episodate.com/tv-show/$(echo $1 | tr '[:upper:]' '[:lower:]' | tr ' ' '-')?season=99" | grep 'and airs on' | sed 's# Season [0-9] / Episode [0-9][0-9] and airs on ##' + lynx -read_timeout=5 -connect_timeout=5 --dump "https://www.episodate.com/tv-show/$(echo $1 | tr '[:upper:]' '[:lower:]' | tr ' ' '-')?season=99" 2>&1 | grep 'and airs on' | sed 's# Season [0-9]\+ / Episode [0-9]\+ and airs on ##' return } @@ -83,7 +83,7 @@ function torrent { for i in $(tail -n +3 "$1"); do getmagnetlink "$i" if [ "$magnetlink" != "" ]; then - /usr/bin/transmission-cli -d 1000 -u 1 -er -w "$downloaddir" -b -f "/usr/local/bin/wolfpack-stoptorrent" "$magnetlink" + /usr/bin/transmission-cli -d 600 -u 1 -er -w "$downloaddir" -b -f "/usr/local/bin/wolfpack-stoptorrent" "$magnetlink" sed -i "/$i/d" "$1" echo Downloaded and removed $i | tee -a $logfile fi @@ -111,7 +111,7 @@ function shows { if [ "$magnetlink" != "" ]; then # We found an episode. echo $i | tee -a $logfile - # /usr/bin/transmission-cli -d 600 -u 1 -er -w "$downloaddir" -b -f "/usR/Local/bin/wolfpack-stoptorrent" "$magnetlink" + /usr/bin/transmission-cli -d 300 -u 1 -er -w "$downloaddir" -b -f "/usr/local/bin/wolfpack-stoptorrent" "$magnetlink" sed -i "s/$i/S${season}E${newep}#${showName}#${modifier}/" "$1" echo Downloaded and pup updated. | tee -a $logfile rm -Rf ~/.config/transmission/resume/* @@ -165,7 +165,7 @@ function download { echo Deduped! Removed $i from $downloaddir | tee -a $logfile rm -Rf $i; done - wget -q -O "$filename" "$nexturl" + wget --timeout=5 -q -O "$filename" "$nexturl" echo Downloaded | tee -a $logfile fi }