From f961ecc638751cdef8a32c02ec2ccc4308e104cc Mon Sep 17 00:00:00 2001 From: Cyril Brulebois Date: Fri, 15 May 2015 04:37:43 +0200 Subject: Detect incompatible options and abort accordingly. --- debootstrap | 6 ++++++ debootstrap.8 | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/debootstrap b/debootstrap index e987112..2bbd1ac 100755 --- a/debootstrap +++ b/debootstrap @@ -365,6 +365,12 @@ fi ########################################################################### +if [ -n "$DISABLE_KEYRING" -a -n "$FORCE_KEYRING" ]; then + error 1 BADARG "Both --no-check-gpg and --force-check-gpg specified, please pick one (at most)" +fi + +########################################################################### + if [ "$SECOND_STAGE_ONLY" = "true" ]; then SUITE=$(cat $DEBOOTSTRAP_DIR/suite) ARCH=$(cat $DEBOOTSTRAP_DIR/arch) diff --git a/debootstrap.8 b/debootstrap.8 index 106d172..a2b4dff 100644 --- a/debootstrap.8 +++ b/debootstrap.8 @@ -95,7 +95,7 @@ Disables checking gpg signatures of retrieved Release files. .IP .IP "\fB\-\-force-check-gpg\fP" Forces checking Release file signatures, disabling automatic fallback to -HTTPS in case of a missing keyring. +HTTPS in case of a missing keyring. Incompatible with the previous option. .IP .IP "\fB\-\-verbose\fP" Produce more info about downloading. -- cgit v0.12