summaryrefslogtreecommitdiffstats
path: root/debian/powerline.postinst
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 16:40:17 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 16:40:17 +0000
commit38a4353f63924f0734ee6d85efdf848a6d93bc7e (patch)
treea62557ea80510890872e67e39fd4de63167b9db7 /debian/powerline.postinst
parentAdding upstream version 2.8.3. (diff)
downloadpowerline-debian.tar.xz
powerline-debian.zip
Adding debian version 2.8.3-4.debian/2.8.3-4debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/powerline.postinst')
-rw-r--r--debian/powerline.postinst38
1 files changed, 38 insertions, 0 deletions
diff --git a/debian/powerline.postinst b/debian/powerline.postinst
new file mode 100644
index 0000000..135678e
--- /dev/null
+++ b/debian/powerline.postinst
@@ -0,0 +1,38 @@
+#!/bin/sh
+
+set -e
+
+case "${1}" in
+ configure)
+ . /usr/share/debconf/confmodule
+
+ db_get powerline/enable
+ POWERLINE_ENABLE="${RET}" # boolean
+
+ db_stop
+
+ rm -f /etc/profile.d/zz-powerline.sh
+
+ for ENABLE in $(echo ${POWERLINE_ENABLE} | sed -e 's|,| |g')
+ do
+ case "${ENABLE}" in
+ bash)
+ ln -sf /usr/share/powerline/integrations/powerline.sh /etc/profile.d/zz-powerline.sh
+ ;;
+ esac
+ done
+ ;;
+
+ abort-upgrade|abort-remove|abort-deconfigure)
+
+ ;;
+
+ *)
+ echo "postinst called with unknown argument \`${1}'" >&2
+ exit 1
+ ;;
+esac
+
+#DEBHELPER#
+
+exit 0