[Pkg-zsh-commits] [SCM] Debian zsh package branch, debian, updated. debian/5.0.2-2-15-ge4bf431

Axel Beckert abe at deuxchevaux.org
Thu Jan 10 00:16:42 UTC 2013


The following commit has been merged in the debian branch:
commit e4bf431fae75fc53f2abb9bb44c149fc22f46841
Author: Axel Beckert <abe at deuxchevaux.org>
Date:   Thu Jan 10 01:11:26 2013 +0100

    zsh{,-dbg}.postinst: Create symlink to /usr/share/doc/zsh-common (Closes: #697808)
    
    On purpose, dpkg doesn't replace directories with symlinks and
    vice-versa. Has to be done manually in the maintainer scripts.
    
    Thanks: Sebastian Ramacher <sramacher at debian.org>

diff --git a/debian/zsh-dbg.postinst b/debian/zsh-dbg.postinst
new file mode 100644
index 0000000..dac01ba
--- /dev/null
+++ b/debian/zsh-dbg.postinst
@@ -0,0 +1,28 @@
+#!/bin/sh
+
+set -e
+
+case "$1" in
+    (configure)
+        :
+    ;;
+    (abort-upgrade|abort-remove|abort-deconfigure)
+	exit 0
+    ;;
+    (*)
+	echo "postinst called with unknown argument \`$1'" >&2
+	exit 0
+    ;;
+esac
+
+# Replace documentation directory with symlink
+docdir="/usr/share/doc/zsh-dbg"
+if [ -d $docdir -a ! -L $docdir ]; then
+    if rmdir $docdir 2>/dev/null; then
+        ln -sf zsh-common $docdir
+    fi
+fi
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/zsh.postinst b/debian/zsh.postinst
index c9be2eb..0224d50 100644
--- a/debian/zsh.postinst
+++ b/debian/zsh.postinst
@@ -26,6 +26,14 @@ update-alternatives --install /bin/zsh zsh /bin/zsh5 50 \
 update-alternatives --install /bin/rzsh rzsh /bin/zsh5 50 \
 		--slave /usr/share/man/man1/rzsh.1.gz rzsh.1.gz /usr/share/man/man1/zsh.1.gz
 
+# Replace documentation directory with symlink
+docdir="/usr/share/doc/zsh"
+if [ -d $docdir -a ! -L $docdir ]; then
+    if rmdir $docdir 2>/dev/null; then
+        ln -sf zsh-common $docdir
+    fi
+fi
+
 #DEBHELPER#
 
 exit 0

-- 
Debian zsh package



More information about the Pkg-zsh-commits mailing list