wiki:Scripts

Version 1 (modified by Waldorf, 12 years ago) (diff)

Waldorf: Still a work in progress. I was thinking of this as a portal, and each script in it's own page?

Transmission Scripts

These will mainly be command-line scrips using the transmission-remote.

Category 1

Block List Updater

#!/bin/sh

PID="`pidof transmission-daemon`"
if [ -n "$PID" ]; then
        kill $PID
fi

echo -n "Waiting for the daemon to exit "
sleep 2

COUNT=1
while [ -n "`pidof transmission-daemon`" ]; do
        COUNT=$((COUNT + 1))
        if [ $COUNT -gt 60 ]; then
                echo -n "transmission-daemon doesn't respond, killing it with -9"
                kill -9 `pidof transmission-daemon`
                break
        fi

        sleep 2
        echo -n "."
done

echo " done"

cd $HOME/.config/transmission-daemon/blocklists/
if wget http://www.bluetack.co.uk/config/level1.gz 1>/dev/null 2>&1 ; then
        rm -f level1 && gunzip level1.gz
        echo "blocklist updated"
else
        echo "blocklist not updated"
fi

transmission-daemon

Category 2

Category 3

Category 4


Comments

Waldorf: Still a work in progress. I was thinking of this as a portal, and each script in it's own page?
wereHamster: http://pastie.org/338556 http://pastie.org/338555 http://pastie.org/338552