PKGBUILDs/extra/pinball/pinball.install
2009-10-09 21:23:22 -05:00

30 lines
1.1 KiB
Text

post_install() {
touch var/games/pinball/{professor,tux}/highscores
chown root:games var/games/pinball/{professor,tux}/highscores
chmod 664 var/games/pinball/{professor,tux}/highscores
}
pre_upgrade() {
chown root:games var/games/pinball/{professor,tux}
chmod 775 var/games/pinball/{professor,tux}
cp var/games/pinball/professor/highscores var/games/pinball/professor/highscores.bak.pre_upgrade
cp var/games/pinball/tux/highscores var/games/pinball/tux/highscores.bak.pre_upgrade
}
post_upgrade() {
if [ -e var/games/pinball/professor/highscores.bak.pre_upgrade ]; then
mv var/games/pinball/professor/highscores.bak.pre_upgrade var/games/pinball/professor/highscores
fi
if [ -e var/games/pinball/tux/highscores.bak.pre_upgrade ]; then
mv var/games/pinball/tux/highscores.bak.pre_upgrade var/games/pinball/tux/highscores
fi
touch var/games/pinball/professor/highscores
chown root:games var/games/pinball/professor/highscores
chmod 664 var/games/pinball/professor/highscores
touch var/games/pinball/tux/highscores
chown root:games var/games/pinball/tux/highscores
chmod 664 var/games/pinball/tux/highscores
}