blob: d1d020c969c1736b75760da077bbaa57f6d3312f (
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
|
#!/bin/sh
post_install() {
cat <<-EOM
> For instructions see section 'Usage' in:
> /usr/share/doc/pacredir/README.md
> ... or visit:
> https://github.com/eworm-de/pacredir#usage
EOM
}
post_upgrade() {
# return if old package version greater 0.5...
(( $(vercmp $2 '0.5') > 0 )) && return
# upgrade from pre-0.5 version, avahi service names changed
cat <<-EOM
> This upgrade from pacredir $2 to pacredir $1 changes avahi service
> names. Make sure to update all your installations for compatibility.
> The services will be restarted post transaction.
EOM
# mark for restart
for UNIT in pac{redir,serve}.service; do
systemctl set-property --runtime "${UNIT}" Markers=needs-restart
done
}
|