From 1433ebcc1c4a087ad1c4f58170357b7faf520bd5 Mon Sep 17 00:00:00 2001 From: Antoine Jacoutot Date: Mon, 2 Sep 2013 09:41:04 +0200 Subject: [PATCH] Make openup -c mutually exclusive with other options. --- openup | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/openup b/openup index 7a67a2b..d4969fb 100755 --- a/openup +++ b/openup @@ -37,13 +37,14 @@ _OPENUP_MINREL=53 usage() { echo - echo "Usage: ${0##*/} [-SUn]" >&2 + echo "Usage: ${0##*/} [-SUn]|[-c]" >&2 echo echo "Options:" echo " -S do not check for package signatures" echo " -U do not check for openup update" - echo " -c check/cron mode, other options are ignored" echo " -n dry-run mode, no modification is done" + echo + echo " -c check/cron mode, mutually exclusive with other options" exit 1 } @@ -215,7 +216,11 @@ if [ -z "${checkmode}" ]; then update_binpatches update_pkg else - check_vuxml + if [ "${nosig}" -o "${noselfupdate}" -o "${dryrun}" ]; then + usage + else + check_vuxml + fi fi rm -f ${_TMPDIR}/openup-*