initial release
[roundcube-cn.git] / debian / postrm
1 #!/bin/sh
2
3 set -e
4
5 # Debconf
6 . /usr/share/debconf/confmodule
7
8 PKG=roundcube-cn
9
10 if [ -e /usr/share/apache2/apache2-maintscript-helper ]; then
11     . /usr/share/apache2/apache2-maintscript-helper
12
13     roundcube_enable() {
14         echo "CN: Purging $PKG configuration for Apache2."
15         return 0
16     }
17 else
18     echo "CN: Could not load Apache 2.4 maintainer script helper."
19
20     roundcube_enable() {
21         return 1
22     }
23 fi
24
25 if [ "$1" = "purge" ] ; then
26     if roundcube_enable; then
27         apache2_invoke disconf $PKG
28     fi
29
30     if [ "`readlink -q -m /etc/apache2/conf-available/$PKG.conf`" = /etc/roundcube/apache.conf ]; then
31         rm -f /etc/apache2/conf-available/$PKG.conf
32     fi
33 fi
34
35 #DEBHELPER#
36
37 exit 0