commit:     77b64b1e27c90a569ab198fb945791e3b7dc97a4
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Tue Jan 27 00:25:54 2026 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Jan 27 00:26:27 2026 +0000
URL:        
https://gitweb.gentoo.org/proj/gentoo-authority-key.git/commit/?id=77b64b1e

autosign.bash: handle gpg failure w/ pipestatus in get_signed_keys, refresh_keys

Signed-off-by: Sam James <sam <AT> gentoo.org>

 autosign.bash | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/autosign.bash b/autosign.bash
index f77289b..c698810 100755
--- a/autosign.bash
+++ b/autosign.bash
@@ -29,7 +29,8 @@ die() {
 refresh_keys() {
        # we trust qa-scripts to refresh them for us
        wget -q -O - https://qa-reports.gentoo.org/output/active-devs.gpg |
-               gpg -q --import || die "Failed to refresh keys"
+               gpg -q --import
+       pipestatus || die "Failed to refresh keys: $?"
 }
 
 # Get UID-fingerprint mapping from LDAP, for active devs.
@@ -106,7 +107,8 @@ get_signed_keys() {
                                        printf "%s\t%s\n" "${email,,}" "${fpr}"
                                ;;
                esac
-       done < <(gpg --with-colons --list-keys)
+       done < <(gpg --with-colons --list-keys || die "gpg query for signed 
keys failed")
+       pipestatus || die "gpg query for signed keys failed: $?"
 }
 
 # Revoke the specified UID signature.

Reply via email to