summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rw-r--r--scripts/repo-add.sh.in12
1 files changed, 11 insertions, 1 deletions
diff --git a/scripts/repo-add.sh.in b/scripts/repo-add.sh.in
index c50c47da..00d3a416 100644
--- a/scripts/repo-add.sh.in
+++ b/scripts/repo-add.sh.in
@@ -554,7 +554,17 @@ while [[ $# > 0 ]]; do
-q|--quiet) QUIET=1;;
-d|--delta) DELTA=1;;
-f|--files) WITHFILES=1;;
- -s|--sign) SIGN=1;;
+ -s|--sign)
+ SIGN=1
+ if ! gpg --list-key ${GPGKEY} &>/dev/null; then
+ if [[ ! -z $GPGKEY ]]; then
+ error "$(gettext "The key ${GPGKEY} does not exist in your keyring.")"
+ else
+ error "$(gettext "There is no key in your keyring.")"
+ fi
+ exit 1
+ fi
+ ;;
-k|--key)
shift
GPGKEY="$1"