mirror of
https://github.com/YunoHost-Apps/movim_ynh.git
synced 2024-09-03 19:46:19 +02:00
27 lines
865 B
Bash
Executable file
27 lines
865 B
Bash
Executable file
#!/bin/sh
|
|
|
|
if [ "$1" = "remove" ] || [ "$1" = "purge" ] ; then
|
|
CONF="movim"
|
|
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 $CONF || exit $?
|
|
elif [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then
|
|
[ ! -L /etc/apache2/conf.d/$CONF.conf ] || rm /etc/apache2/conf.d/$CONF.conf
|
|
fi
|
|
|
|
if [ "$1" = purge ]; then
|
|
rm -rf /var/cache/movim /etc/movim /usr/share/movim /var/log/movim
|
|
db_purge
|
|
fi
|
|
fi
|
|
|
|
if [ -f /usr/share/debconf/confmodule ]; then
|
|
. /usr/share/debconf/confmodule
|
|
fi
|
|
if [ -f /usr/share/dbconfig-common/dpkg/postrm ]; then
|
|
. /usr/share/dbconfig-common/dpkg/postrm
|
|
dbc_go movim $@
|
|
fi
|
|
|