rewind

Example 3.6. /home/cweiske/scripts/rewind

#!/bin/sh
if [ `dcop | grep kaffeine -c` -gt 0 ]
then
    dcop kaffeine PlaybackControl posMinus
elif [ `pgrep tvtime` ]
then
    tvtime-command CHANNEL_DOWN
elif [ `dcop | grep kwintv -c` -gt 0 ]
then
    dcop kwintv KWinTVIface channelDown
else
    xmms -r
fi