Fix invirt-base's handling of triggers. 0.0.30
authorEvan Broder <broder@mit.edu>
Thu, 28 Jan 2010 05:24:00 +0000 (00:24 -0500)
committerEvan Broder <broder@mit.edu>
Thu, 28 Jan 2010 05:24:00 +0000 (00:24 -0500)
svn path=/trunk/packages/invirt-base/; revision=2966

debian/changelog
debian/invirt-base.postinst
scripts/invirt-reload

index 3d3f987..ff1b3fb 100644 (file)
@@ -1,3 +1,9 @@
+invirt-base (0.0.30) unstable; urgency=low
+
+  * Cleanup the handling of triggers...so that it actually works.
+
+ -- Evan Broder <broder@mit.edu>  Thu, 28 Jan 2010 00:22:21 -0500
+
 invirt-base (0.0.29) unstable; urgency=low
 
   [ Greg Brockman ]
 invirt-base (0.0.29) unstable; urgency=low
 
   [ Greg Brockman ]
index 73ea19b..2ca852d 100755 (executable)
@@ -26,11 +26,7 @@ case "$1" in
     ;;
 
     triggered)
     ;;
 
     triggered)
-        if dpkg --compare-versions "$DPKG_RUNNING_VERSION" ge '1.14.5ubuntu10~~'; then
-            invirt-reload
-        else
-            DPKG_MAINTSCRIPT_PACKAGE='' invirt-reload
-        fi
+        INVIRT_RELOAD_NOTRIGGER=y invirt-reload
     ;;
 
     *)
     ;;
 
     *)
index 84dbe7a..7792f50 100755 (executable)
@@ -1,9 +1,10 @@
 #!/bin/bash
 
 #!/bin/bash
 
-if [ "$DPKG_MAINTSCRIPT_PACKAGE" != '' ] && \
+if [ x"$INVIRT_RELOAD_NOTRIGGER" = x ] && \
+    [ "$DPKG_MAINTSCRIPT_PACKAGE" != '' ] && \
     [ $# = 0 ] && \
     dpkg-trigger --check-supported 2>/dev/null; then
     [ $# = 0 ] && \
     dpkg-trigger --check-supported 2>/dev/null; then
-    if dpkg-trigger --no-await invirt-base; then
+    if dpkg-trigger --no-await invirt-reload; then
         echo "invirt-reload: deferring update (trigger activated)"
         exit 0
     fi
         echo "invirt-reload: deferring update (trigger activated)"
         exit 0
     fi