summaryrefslogtreecommitdiffstats
path: root/dilos/tdebase/debian/tdm-trinity.postrm
diff options
context:
space:
mode:
authorDenis Kozadaev <denis@dilos.org>2020-01-30 22:13:12 +0300
committerSlávek Banko <slavek.banko@axis.cz>2020-03-02 23:40:36 +0100
commit54987baa2946868ae04e93090d4da5693afaa3b1 (patch)
tree6a989c0fb1d22986af268dcd240803f52a60b433 /dilos/tdebase/debian/tdm-trinity.postrm
parent5593d90a563fc02f6baf3316388f13b9b8957cd0 (diff)
downloadtde-packaging-54987baa2946868ae04e93090d4da5693afaa3b1.tar.gz
tde-packaging-54987baa2946868ae04e93090d4da5693afaa3b1.zip
DilOS: tdebase build pack
Signed-off-by: Denis Kozadaev <denis@dilos.org> (cherry picked from commit 042414011edfd405230b65e77e2b14870852760f)
Diffstat (limited to 'dilos/tdebase/debian/tdm-trinity.postrm')
-rw-r--r--dilos/tdebase/debian/tdm-trinity.postrm51
1 files changed, 51 insertions, 0 deletions
diff --git a/dilos/tdebase/debian/tdm-trinity.postrm b/dilos/tdebase/debian/tdm-trinity.postrm
new file mode 100644
index 000000000..2454461f4
--- /dev/null
+++ b/dilos/tdebase/debian/tdm-trinity.postrm
@@ -0,0 +1,51 @@
+#!/bin/sh -e
+
+if [ "${BASEDIR:=/}" = "/" ]; then
+ BASEDIR=""
+fi
+
+case "$1" in
+ purge)
+ rm -rf /var/log/tdm-trinity.log*
+ ;;
+
+ remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+
+ ;;
+
+ *)
+ echo "postrm called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+if [ "$1" = "abort-install" -o "$1" = "abort-upgrade" ]; then
+ # roll back displacement of default display manager file
+ if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE.dpkg-tmp" ]; then
+ # FIXME - redo this part uses shell-lib.sh from xfree86
+ #observe "rolling back change of default X display manager"
+ mv "$DEFAULT_DISPLAY_MANAGER_FILE.dpkg-tmp" "$DEFAULT_DISPLAY_MANAGER_FILE"
+ fi
+fi
+
+if [ "$1" = "purge" ]; then
+ for DIR in /var/lib/tdm-trinity; do
+ if [ -d "$DIR" ]; then
+ rm -rf "$DIR"
+ fi
+ done
+ rm -f /var/log/tdm-trinity.log*
+fi
+
+#if [ "$1" = "purge" ] ; then
+# if [ -x "`which update-rc.d 2>/dev/null`" ]; then
+# update-rc.d tdm remove >/dev/null || true
+# fi
+#fi
+#if [ -d /run/systemd/system ] ; then
+# systemctl --system daemon-reload >/dev/null || true
+#fi
+
+#DEBHELPER#
+
+exit 0