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

autosign.bash: drop semi-useless `die` to avoid mangling exit code

We want pipestatus to see the real one to surface in an error message, so
don't use `die` prematurely where it can't result in exit (because subshell,
as we're not in an ebuild).

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

 autosign.bash | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/autosign.bash b/autosign.bash
index c698810..65d77c0 100755
--- a/autosign.bash
+++ b/autosign.bash
@@ -66,8 +66,7 @@ get_ldap() {
                                die "Unknown LDAP data: ${l}"
                                ;;
                esac
-       done < <(ldapsearch -Z -D '' -LLL 
"${AUTOSIGN_FILTER:-(gentooStatus=active)}" gpgfingerprint ||
-               die "LDAP query failed")
+       done < <(ldapsearch -Z -D '' -LLL 
"${AUTOSIGN_FILTER:-(gentooStatus=active)}" gpgfingerprint)
        pipestatus || die "LDAP query failed: $?"
 }
 
@@ -107,7 +106,7 @@ get_signed_keys() {
                                        printf "%s\t%s\n" "${email,,}" "${fpr}"
                                ;;
                esac
-       done < <(gpg --with-colons --list-keys || die "gpg query for signed 
keys failed")
+       done < <(gpg --with-colons --list-keys)
        pipestatus || die "gpg query for signed keys failed: $?"
 }
 

Reply via email to