ソースを参照

Update post{inst,rm}

Basically fall back to the templates provided by dh-make.
Christoph Biedl 13 年 前
コミット
b5f63dc07a
2 ファイル変更22 行追加31 行削除
  1. 12 22
      debian/ngircd.postinst
  2. 10 9
      debian/ngircd.postrm

+ 12 - 22
debian/ngircd.postinst

@@ -1,31 +1,21 @@
-#! /bin/sh
-
-# ngircd	Start/stop the Next Generation IRC Server
-# Version:	ngircd  0.9.2  14-Dec-2005
-# Autor:	Mario Iseli <admin@marioiseli.com>
+#!/bin/sh
+# postinst script for ngircd
+#
+# see: dh_installdeb(1)
 
 set -e
 
 case "$1" in
+configure)
+;;
 
-	configure)
-		if [ ! -d "/var/run/ngircd" ]; then
-			mkdir /var/run/ngircd
-			chown irc:irc /var/run/ngircd
-			chmod 770 /var/run/ngircd
-		fi
-		chown -R irc:irc /etc/ngircd
-		chmod 770 /etc/ngircd
-	;;
-
-	abort-upgrade|abort-remove|abort-deconfigure)
-	;;
-
-	*)
-		echo "ERROR: Postinst called with unknown argument!"
-		exit 0
-	;;
+abort-upgrade|abort-remove|abort-deconfigure)
+;;
 
+*)
+    echo "postinst called with unknown argument \`$1'" >&2
+    exit 1
+;;
 esac
 
 #DEBHELPER#

+ 10 - 9
debian/ngircd.postrm

@@ -1,17 +1,18 @@
-#! /bin/sh
-
-# ngircd	Start/stop the Next Generation IRC Server
-# Version:	ngircd  0.9.2  16-Nov-2005
-# Autor:	Mario Iseli <admin@marioiseli.com>
+#!/bin/sh
+# postrm script for ngircd
+#
+# see: dh_installdeb(1)
 
 set -e
 
 case "$1" in
-	purge)
-		rm -rf /etc/ngircd
-		rm -rf /var/run/ngircd
-	;;
+purge|remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+;;
 
+*)
+    echo "postrm called with unknown argument \`$1'" >&2
+    exit 1
+;;
 esac
 
 #DEBHELPER#