[Piuparts-commits] rev 829 - piatti/org/piuparts.debian.org/etc/scripts piatti/org/piuparts.debian.org/htdocs trunk trunk/debian

Holger Levsen holger at alioth.debian.org
Sun Nov 28 00:24:30 UTC 2010


Author: holger
Date: 2010-11-28 00:24:21 +0000 (Sun, 28 Nov 2010)
New Revision: 829

Added:
   piatti/org/piuparts.debian.org/etc/scripts/pre_remove_exceptions
Modified:
   piatti/org/piuparts.debian.org/htdocs/index.tpl
   trunk/README.txt
   trunk/debian/changelog
   trunk/piuparts.py
Log:
<b>2010-11-28</b>: debconf-english is the seventh package getting special treatment by piuparts: before removal, debconf-i18n is installed (see <a href="http://bugs.debian.org/539146" target="_blank">#539146</a> has the details and the news entry for 2010-11-25 lists the other six packages.)

+++ trunk/debian/changelog  
+    - new custom script: pre_remove_ (Closes: #539146)



Copied: piatti/org/piuparts.debian.org/etc/scripts/pre_remove_exceptions (from rev 823, piatti/org/piuparts.debian.org/etc/scripts/post_purge_exceptions)
===================================================================
--- piatti/org/piuparts.debian.org/etc/scripts/pre_remove_exceptions	                        (rev 0)
+++ piatti/org/piuparts.debian.org/etc/scripts/pre_remove_exceptions	2010-11-28 00:24:21 UTC (rev 829)
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+log_debug() {
+	echo "Debug: piuparts exception for package $PIUPARTS_OBJECTS"
+}
+
+echo "Debug: running script $0"
+
+#
+# deal with exceptions:
+#
+case $PIUPARTS_OBJECTS in 
+	debconf-english)	log_debug
+				# install debconf-english removed the required
+				# package debconf-i18n and piuparts has no way
+				# to know this.
+				apt-get -y install debconf-i18n
+				;;
+esac
+
+exit 0

Modified: piatti/org/piuparts.debian.org/htdocs/index.tpl
===================================================================
--- piatti/org/piuparts.debian.org/htdocs/index.tpl	2010-11-28 00:10:58 UTC (rev 828)
+++ piatti/org/piuparts.debian.org/htdocs/index.tpl	2010-11-28 00:24:21 UTC (rev 829)
@@ -48,6 +48,11 @@
     </tr>
     <tr class="normalrow">
      <td class="contentcell2">
+      <b>2010-11-28</b>: debconf-english is the seventh package getting special treatment by piuparts: before removal, debconf-i18n is installed (see <a href="http://bugs.debian.org/539146" target="_blank">#539146</a> has the details and the news entry for 2010-11-25 lists the other six packages.)
+     </td>
+    </tr>
+    <tr class="normalrow">
+     <td class="contentcell2">
       <b>2010-11-26</b>: Schedule all 159 failed packages in lenny2squeeze for re-testing.
      </td>
     </tr>

Modified: trunk/README.txt
===================================================================
--- trunk/README.txt	2010-11-28 00:10:58 UTC (rev 828)
+++ trunk/README.txt	2010-11-28 00:24:21 UTC (rev 829)
@@ -146,6 +146,10 @@
 
 'post_install_'
 
+Before *removing* your package, The name of the script must start with:
+
+'pre_remove_'
+
 After *removing* your package, The name of the script must start with:
 
 'post_remove_'

Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog	2010-11-28 00:10:58 UTC (rev 828)
+++ trunk/debian/changelog	2010-11-28 00:24:21 UTC (rev 829)
@@ -60,6 +60,7 @@
     - remove logrotate and depended packages after the test. (Closes: #602409)
       This is a fix for the incomplete patch for #566597. Again, this is a
       hardcoded list. :-(
+    - new custom script: pre_remove_ (Closes: #539146)
     - set environment variable PIUPARTS_OBJECTS in custom scripts to a space
       seperated list of packages / changes files being tested.
     - do not call apt-get with --no-remove when installing packages. 

Modified: trunk/piuparts.py
===================================================================
--- trunk/piuparts.py	2010-11-28 00:10:58 UTC (rev 828)
+++ trunk/piuparts.py	2010-11-28 00:24:21 UTC (rev 829)
@@ -852,10 +852,14 @@
         nondeps_to_purge = [name for name, state in nondeps.iteritems()
                             if state == "purge"]
     
+        # Run custom scripts before removing all packages. 
+	if settings.scriptsdir is not None:
+            self.run_scripts("pre_remove")	
+
         # First remove all packages.
         self.remove_or_purge("remove", deps_to_remove + deps_to_purge +
                                         nondeps_to_remove + nondeps_to_purge)
-        # Run custom scripts after remove all packages. 
+        # Run custom scripts after removing all packages. 
 	if settings.scriptsdir is not None:
             self.run_scripts("post_remove")	
 




More information about the Piuparts-commits mailing list