]> Nutra Git (v1) - gamesguru/git-remote-gcrypt.git/commitdiff
Use filter_to for key_line
authorroot <root@localhost>
Thu, 22 Nov 2012 01:46:46 +0000 (02:46 +0100)
committerroot <root@localhost>
Thu, 22 Nov 2012 01:46:46 +0000 (02:46 +0100)
git-remote-gcrypt

index f159cee2cbf1d9a9cbbf631ec8920a331c6857ff..9373901f7e4ea1c83986a78e0b3981a448f3b71a 100755 (executable)
@@ -422,7 +422,8 @@ read_config()
 
        for recp_ in $conf_part
        do
-               key_line=$(gpg --with-colons --fast-list -k "$recp_" | xgrep ^pub)
+               filter_to @key_line "pub" \
+                       "$(gpg --with-colons --fast-list -k "$recp_")"
                isnull "$key_line" || isnonnull "${key_line##*"$Newline"*}" ||
                echo_info "WARNING: '$recp_' matches multiple keys, using one"
                key_line=${key_line%%"$Newline"*}