blob: 5cbfee1f6a8f5fcc76912b2d9214838c379eb8e3 (
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
|
classname=plugin.video.quasar
usr=420
home=/var/lib/kodi/.kodi/addons
repo=$home/repository.quasar
addonpath=$home/${classname}
_chown() {
chmod 755 $(find $addonpath -type d)
chmod 644 $(find $addonpath -type f)
chown -R $usr:$usr $home $addonpath
}
## arg 1: the new package version
post_install() {
getent passwd $usr &> /dev/null || useradd -r -d $home -s /bin/bash $usr
_chown
}
post_upgrade() {
_chown
}
## arg 1: the old package version
post_remove() {
rm -r $addonpath $repo
return 0
}
# vim:set ts=2 sw=2 et:
|