X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=debian%2Fnfs-common.postrm;h=9abe8c202c04893585baf90dc457eeeada61636c;hb=cd913d4f8784bce54aac91b091813c5c4503c152;hp=4e904174b5370c7a1051efd8417e5960ed250710;hpb=52a03354d4f15bc9333349b366f3545acd32554d;p=nfs-utils.git diff --git a/debian/nfs-common.postrm b/debian/nfs-common.postrm old mode 100755 new mode 100644 index 4e90417..9abe8c2 --- a/debian/nfs-common.postrm +++ b/debian/nfs-common.postrm @@ -1,9 +1,26 @@ #!/bin/sh +set -e + #DEBHELPER# case "$1" in purge) - update-rc.d nfs-common remove >/dev/null 2>&1 + for FILE in /etc/default/nfs-common /etc/idmapd.conf; do + # Taken from the ucf example postrm + for ext in '~' '%' .bak .dpkg-tmp .dpkg-new .dpkg-old .dpkg-dist; do + rm -f $FILE$ext + done + rm -f $FILE + if [ -x /usr/bin/ucf ]; then + ucf --purge $FILE + fi + done + + rm -f /var/lib/nfs/state \ + /var/lib/nfs/sm/* \ + /var/lib/nfs/sm.bak/* + + dpkg-statoverride --remove /sbin/mount.nfs || true ;; esac