#633428 debuild: Add an option to unapply patches for "debuild clean"

Package:
devscripts
Source:
devscripts
Description:
scripts to make the life of a Debian Package maintainer easier
Submitter:
Reinhard Tartler
Date:
2011-07-12 01:27:06 UTC
Severity:
wishlist
#633428#5
Date:
2011-07-10 09:08:31 UTC
From:
To:
please run quilt pop -a when option 'unapply-patches' is set in
debian/source/local-options'. This is espc. handy when working on
packages that are maintained in a VCS.

Thanks for considering.

#633428#10
Date:
2011-07-10 09:38:58 UTC
From:
To:
tags 633428 patch
user ubuntu-devel@lists.ubuntu.com
usertag origin-ubuntu oneiric

I've uploaded this patch to ubuntu:

http://launchpadlibrarian.net/74898075/devscripts_2.11.0ubuntu1_2.11.0ubuntu2.diff.gz

diff -Nru devscripts-2.11.0ubuntu1/scripts/debclean.sh devscripts-2.11.0ubuntu2/scripts/debclean.sh
--- devscripts-2.11.0ubuntu1/scripts/debclean.sh	2011-05-25 03:55:45.000000000 +0000
+++ devscripts-2.11.0ubuntu2/scripts/debclean.sh	2011-07-10 09:13:46.000000000 +0000
@@ -196,6 +196,11 @@
     # We now know we're OK and debuild won't complain about the dirname
     debuild $CHECKBUILDDEP clean

+    # Does the maintainer want to have patches unapplied?
+    if test -x /usr/bin/quilt && grep -qs ^unapply-patches debian/source/local-options; then
+        QUILT_PATCHES=debian/patches quilt pop -a
+    fi
+
     # Clean up the package related files
     if [ "$DEBCLEAN_CLEANDEBS" = yes ]; then
 	cd ..


Cheers