2 # postrm script for privoxy
4 # see: dh_installdeb(1)
8 # summary of how this script can be called:
11 # * <old-postrm> `upgrade' <new-version>
12 # * <new-postrm> `failed-upgrade' <old-version>
13 # * <new-postrm> `abort-install'
14 # * <new-postrm> `abort-install' <old-version>
15 # * <new-postrm> `abort-upgrade' <old-version>
16 # * <disappearer's-postrm> `disappear' <r>overwrit>r> <new-version>
17 # for details, see http://www.debian.org/doc/debian-policy/ or
18 # the debian-policy package
23 # deluser --quiet privoxy
24 for ext in .ucf-new .ucf-old .ucf-dist ""; do
25 rm -f "/etc/privoxy/config$ext"
27 if [ -x "$(command -v ucf)" ]; then
28 ucf --purge /etc/privoxy/config
30 if [ -x "$(command -v ucfr)" ]; then
31 ucfr --purge privoxy /etc/privoxy/config
33 rm -rf /var/log/privoxy
34 if [ -e /usr/share/debconf/confmodule ]; then
35 . /usr/share/debconf/confmodule
38 # Remove https inspection certificates on purge:
39 if [ -d /var/lib/privoxy/certs ]; then
40 rm -rf /var/lib/privoxy/certs
44 remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
48 echo "postrm called with unknown argument \`$1'" >&2
53 # dh_installdeb will replace this with shell code automatically
54 # generated by other debhelper scripts.