[pbuilder] 08/08: modules: remove_packages(): don't remove packages explicitly listed in EXTRAPACKAGES

Mattia Rizzolo mattia at debian.org
Wed Jun 22 12:17:45 UTC 2016


This is an automated email from the git hooks/post-receive script.

mattia pushed a commit to branch master
in repository pbuilder.

commit c2121bb9d6165cfc50d3fa28093c7bafb4fbe651
Author: Mattia Rizzolo <mattia at debian.org>
Date:   Wed Jun 22 12:02:32 2016 +0000

    modules: remove_packages(): don't remove packages explicitly listed in EXTRAPACKAGES
    
    Closes: #827206
---
 pbuilder-modules | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/pbuilder-modules b/pbuilder-modules
index 5a941fa..426688e 100644
--- a/pbuilder-modules
+++ b/pbuilder-modules
@@ -515,7 +515,11 @@ function remove_packages () {
     local toremove=()
     for pkg in "$@"; do
         if (dpkg -s "$pkg" 2>&1)>/dev/null ; then
-            toremove+=("$pkg")
+            if (_contains ${EXTRAPACKAGES[@]} "$pkg" || _contains ${EXTRAPACKAGES[@]} "${pkg}-"); then
+                log.d "not removing $pkg as it's also explicitely listed in EXTRAPACKAGES"
+            else
+                toremove+=("$pkg")
+            fi
         else
             log.d "not removing $pkg as not installed"
         fi

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pbuilder/pbuilder.git



More information about the Pbuilder-maint mailing list