summaryrefslogtreecommitdiffstats
path: root/abs/extra/xscreensaver/xscreensaver.install
blob: a64ab36a1d50cbc3ef5901fbee6eaf74a75540e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# arg 1:  the new package version
post_install() {
	if grep xscreensaver-command /home/mythtv/.mplayer/config
	then
		echo "Nothing to do here..."
	else
	echo "heartbeat-cmd=\"xscreensaver-command -deactivate &\"" >> /home/mythtv/.mplayer/config
fi
}
# arg 1:  the new package version
# arg 2:  the old package version
post_upgrade() {
	 if grep xscreensaver-command /home/mythtv/.mplayer/config
         then
                 echo "Nothing to do here..."
         else
         echo "heartbeat-cmd=\"xscreensaver-command -deactivate &\"" >> /home/mythtv/.mplayer/config
fi
}

# arg 1:  the old package version
post_remove() {
	grep -v xscreensaver /home/mythtv/.mplayer/config > /tmp/mp-config
	mv /tmp/mp-config /home/mythtv/.mplayer/config
	chown mythtv.mythtv /home/mythtv/.mplayer/config
}

op=$1
shift
$op $*