Remove obsolete files and old upgrade paths for users coming from version prior to wheezy
This commit is contained in:
parent
9aba586fa8
commit
3115b529b2
15 changed files with 39 additions and 632 deletions
50
debian/nut-server.postrm
vendored
50
debian/nut-server.postrm
vendored
|
|
@ -1,48 +1,18 @@
|
|||
#!/bin/sh -e
|
||||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
|
||||
case "$1" in
|
||||
|
||||
remove)
|
||||
# remove sample file if those were previously (wrongly) installed
|
||||
for file in ups.conf upsd.conf upsmon.conf upsd.users upssched.conf ; do
|
||||
rm -f /etc/nut/${file}.sample
|
||||
done
|
||||
remove)
|
||||
[ -d /run/nut ] && rmdir --ignore-fail-on-non-empty /run/nut >/dev/null 2>&1
|
||||
;;
|
||||
purge|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
|
||||
;;
|
||||
|
||||
purge)
|
||||
# remove udev rules files
|
||||
rm -f /etc/udev/rules.d/025_nut-usbups.rules
|
||||
rm -f /etc/udev/rules.d/52_nut-usbups.rules
|
||||
rm -f /etc/udev/rules.d/52-nut-usbups.rules
|
||||
# handle a dpkg bug
|
||||
[ -d /etc/nut ] && rmdir --ignore-fail-on-non-empty /etc/nut >/dev/null 2>&1
|
||||
*)
|
||||
echo "postrm called with unknown argument \`$1'" >&2
|
||||
exit 1
|
||||
;;
|
||||
|
||||
upgrade)
|
||||
# do nothing
|
||||
;;
|
||||
|
||||
failed-upgrade)
|
||||
# do nothing
|
||||
;;
|
||||
|
||||
abort-install)
|
||||
# do nothing
|
||||
;;
|
||||
|
||||
abort-upgrade)
|
||||
# do nothing
|
||||
;;
|
||||
|
||||
disappear)
|
||||
# do nothing
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "$0: incorrect arguments: $*" >&2
|
||||
exit 1
|
||||
;;
|
||||
|
||||
esac
|
||||
|
||||
#DEBHELPER#
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue