[DRE-commits] [SCM] ruby-thin.git branch, master, updated. upstream/1.2.11-39-g7ad4964

Ryan Niebur ryanryan52 at gmail.com
Tue Jan 24 18:49:14 UTC 2012


The following commit has been merged in the master branch:
commit 7ad4964993670c8cbd6be6c6bab115e249944301
Author: Ryan Niebur <ryanryan52 at gmail.com>
Date:   Tue Jan 24 10:48:32 2012 -0800

    completely switch to using dpkg-maintscript-helper, since it is smarter about detecting things

diff --git a/debian/thin.postinst b/debian/thin.postinst
new file mode 100644
index 0000000..92ae268
--- /dev/null
+++ b/debian/thin.postinst
@@ -0,0 +1,9 @@
+# complete dpkg-maintscript-helper operations
+
+if [ -h /etc/init.d/thin.dpkg-remove ] || [ -h /etc/init.d/thin.dpkg-backup ]; then
+   dpkg-maintscript-helper rm_conffile /etc/init.d/thin 1.2.4-1.1 thin -- "$@"
+fi
+
+if [ -e /etc/init.d/thin1.8.dpkg-remove ] || [ -e /etc/init.d/thin1.8.dpkg-backup ]; then
+   dpkg-maintscript-helper rm_conffile /etc/init.d/thin1.8 1.2.4-1.1 thin1.8 -- "$@"
+fi
diff --git a/debian/thin.postrm b/debian/thin.postrm
new file mode 100644
index 0000000..4457717
--- /dev/null
+++ b/debian/thin.postrm
@@ -0,0 +1,10 @@
+# complete dpkg-maintscript-helper operations
+
+if [ -h /etc/init.d/thin.dpkg-remove ] || [ -h /etc/init.d/thin.dpkg-backup ]; then
+   dpkg-maintscript-helper rm_conffile /etc/init.d/thin 1.2.4-1.1 thin -- "$@"
+fi
+
+if [ -e /etc/init.d/thin1.8.dpkg-remove ] || [ -e /etc/init.d/thin1.8.dpkg-backup ]; then
+   dpkg-maintscript-helper rm_conffile /etc/init.d/thin1.8 1.2.4-1.1 thin1.8 -- "$@"
+fi
+
diff --git a/debian/thin.preinst b/debian/thin.preinst
index 6f9ff83..747aa32 100644
--- a/debian/thin.preinst
+++ b/debian/thin.preinst
@@ -1,6 +1,6 @@
 # Just check if the old thin init.d conffile symlink needs to be removed
 if [ -h /etc/init.d/thin ] && [ "$(readlink /etc/init.d/thin)" = "thin1.8" ]; then
-  rm -f /etc/init.d/thin
+  dpkg-maintscript-helper rm_conffile /etc/init.d/thin 1.2.4-1.1 thin -- "$@"
   update-rc.d thin remove
 fi
 
@@ -10,8 +10,4 @@ if [ -f /etc/init.d/thin1.8 ]; then
    update-rc.d thin1.8 remove
 fi
 
-# Removed following conditions, in case prior thin package was installed and removed, but not purged (and thin1.8 was purged? this is a corner case, I admit)
-# if [ "$1" = "install" -a -e /etc/init.d/thin1.8 ] || ([ "$1" = "upgrade" ] && dpkg --compare-versions "$1" lt 1.3.1-1); then
-# fi
-
 #DEBHELPER#

-- 
ruby-thin.git



More information about the Pkg-ruby-extras-commits mailing list