From 213950afa370296b921230e6edc626e70a71b499 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Wed, 21 Sep 2011 14:22:07 -0500 Subject: pacman-key: simplify import in populate This finishes the cleanup started in 710e83999bbf. We can do a straight import from another keyring rather than all the funky parsing and piping business we were doing. Signed-off-by: Dan McGee --- scripts/pacman-key.sh.in | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'scripts') diff --git a/scripts/pacman-key.sh.in b/scripts/pacman-key.sh.in index 1bd6c25f..39da83da 100644 --- a/scripts/pacman-key.sh.in +++ b/scripts/pacman-key.sh.in @@ -232,7 +232,6 @@ verify_keyring_input() { populate_keyring() { local KEYRING_IMPORT_DIR='@pkgdatadir@/keyrings' - local GPG_NOKEYRING=(gpg --batch --quiet --ignore-time-conflict --no-options --no-default-keyring --homedir ${PACMAN_KEYRING_DIR} --no-permission-warning) local keyring local ret=0 @@ -270,10 +269,7 @@ populate_keyring() { # Add keys from requested keyrings for keyring in "${KEYRINGIDS[@]}"; do msg "$(gettext "Appending keys from %s.gpg...")" "$keyring" - local add_keys="$("${GPG_NOKEYRING[@]}" --keyring "${KEYRING_IMPORT_DIR}/${keyring}.gpg" --with-colons --list-keys | grep ^pub | cut -d: -f5)" - for key_id in ${add_keys}; do - "${GPG_NOKEYRING[@]}" --keyring "${KEYRING_IMPORT_DIR}/${keyring}.gpg" --export "${key_id}" | "${GPG_PACMAN[@]}" --import - done + "${GPG_PACMAN[@]}" --import "${KEYRING_IMPORT_DIR}/${keyring}.gpg" done # Read the revoked key IDs to an array. The conversion from whatever is inside the file -- cgit v1.2.3-70-g09d2