File: postrm

package info (click to toggle)
spip 3.0.17-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie-kfreebsd
  • size: 30,776 kB
  • sloc: php: 200,550; xml: 4,367; sh: 272; makefile: 39
file content (33 lines) | stat: -rw-r--r-- 769 bytes parent folder | download | duplicates (3)
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
31
32
33
#! /bin/sh
# postrm script for spip
#
# see: dh_installdeb(1)

set -e

if [ -f /usr/share/debconf/confmodule ]; then
. /usr/share/debconf/confmodule
fi

case "$1" in
    purge)
	CONF="spip"
	COMMON_STATE=$(dpkg-query -f '${Status}' -W 'apache2.2-common' 2>/dev/null | awk '{print $3}' || true)

	if [ -e /usr/share/apache2/apache2-maintscript-helper ] ; then
		. /usr/share/apache2/apache2-maintscript-helper
		apache2_invoke disconf spip.conf
	elif [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then
		[ -L /etc/apache2/conf.d/$CONF.conf ] && rm /etc/apache2/conf.d/$CONF.conf
	fi
        rm -rf /etc/spip /var/lib/spip /etc/apache2/conf-available/spip.conf /etc/cherokee/sites-available/spip
    ;;
    *)
    ;;
esac


#DEBHELPER#

exit 0