aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMattia Rizzolo <mattia@mapreri.org>2015-11-15 12:15:41 +0000
committerMattia Rizzolo <mattia@mapreri.org>2015-11-15 12:15:41 +0000
commit80fd45b30a52bba481f928bf912bdbe0acc19558 (patch)
tree9a473de6609e07decc2c72d6a2780c1895de2d18
parentc99fc84f84b9ac9c5c2501795712ce8bdb3e97ff (diff)
downloadpbuilder-80fd45b30a52bba481f928bf912bdbe0acc19558.tar
pbuilder-80fd45b30a52bba481f928bf912bdbe0acc19558.tar.gz
checkparams: override "experimental" DISTRIBUTION only for the create and update target
-rwxr-xr-xpbuilder-checkparams18
1 files changed, 12 insertions, 6 deletions
diff --git a/pbuilder-checkparams b/pbuilder-checkparams
index 54ed075..f711665 100755
--- a/pbuilder-checkparams
+++ b/pbuilder-checkparams
@@ -310,12 +310,18 @@ case "$LOGLEVEL" in
esac
# handle 'experimental' specially. -- required for raw pbuilder (create/update) only.
-if [ "$DISTRIBUTION" = "experimental" ]; then
- DISTRIBUTION="sid"
- EXPERIMENTAL="true"
-else
- EXPERIMENTAL=
-fi
+case "$PBCURRENTCOMMANDLINEOPERATION" in
+ --update|update|--create|create)
+ if [ "$DISTRIBUTION" = "experimental" ]; then
+ DISTRIBUTION="sid"
+ EXPERIMENTAL="true"
+ else
+ EXPERIMENTAL=""
+ fi
+ ;;
+ *) EXPERIMENTAL="" ;;
+esac
+
case "$PBCURRENTCOMMANDLINEOPERATION" in
--login|login|--execute|execute|--pdebuild|pdebuild)