blob: 0c6ed5aca492c156a5de09fe9845db4fe05a6f90 (
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
31
32
|
# arg 1: the new package version
post_install() {
touch /usr/lib/zangband/apex/scores.raw
chown root:users /usr/lib/zangband/apex/scores.raw
chmod 664 /usr/lib/zangband/apex/scores.raw
}
# arg 1: the new package version
# arg 2: the old package version
pre_upgrade() {
find /usr/share/zangband -type d -exec chmod 774 {} \;
find /usr/share/zangband -type f -exec chmod 664 {} \;
}
# arg 1: the new package version
# arg 2: the old package version
post_upgrade() {
mv /usr/share/zangband/lib/apex/* /usr/lib/zangband/apex
mv /usr/share/zangband/lib/data/* /usr/lib/zangband/data
mv /usr/share/zangband/lib/save/* /usr/lib/zangband/save
rm -fr /usr/share/zangband
}
# arg 1: the old package version
post_remove() {
rm -fr /usr/lib/zangband
cat << EOM
==> All data from /usr/lib/zangband erased
EOM
}
|