Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/update-keys
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2020-01-13 09:18:29 +0100
committerErich Eckner <git@eckner.net>2020-01-13 09:18:29 +0100
commitd8a006b4f28917c7e675d2eeea5c925a5171e334 (patch)
treec546f178b9b62de1c0d1dcab69acbcbfe0c3c894 /update-keys
parentece81d941bf6d7755b4a6cec1dbabe7b97bd699d (diff)
update-keys: make local gpg and gpg on buildmaster silent, too, ane more importantly: not swallow input
Diffstat (limited to 'update-keys')
-rwxr-xr-xupdate-keys19
1 files changed, 10 insertions, 9 deletions
diff --git a/update-keys b/update-keys
index ca68887..5c7592a 100755
--- a/update-keys
+++ b/update-keys
@@ -6,7 +6,8 @@ TMPDIR=$(mktemp -d)
trap "rm -rf '${TMPDIR}'" EXIT
KEYSERVER='hkp://keys.gnupg.net'
-GPG="gpg --quiet --batch --no-tty --no-permission-warning --keyserver "${KEYSERVER}" --homedir ${TMPDIR}"
+GPG_OPTIONS='--quiet --batch --no-tty --no-permission-warning'
+GPG="gpg ${GPG_OPTIONS} --keyserver "${KEYSERVER}" --homedir ${TMPDIR}"
pushd "$(dirname "$0")" >/dev/null
@@ -31,8 +32,8 @@ while read -ra data; do
keyid="${data[0]}"
username="${data[@]:1}"
${GPG} --recv-keys ${keyid} &>/dev/null
- gpg -a --export ${keyid} | ${GPG} --import &>/dev/null
- ssh buildmaster "gpg -a --export ${keyid}" | ${GPG} --import &>/dev/null
+ gpg ${GPG_OPTIONS} -a --export ${keyid} </dev/null | ${GPG} --import &>/dev/null
+ ssh buildmaster "gpg ${GPG_OPTIONS} -a --export ${keyid}" </dev/null | ${GPG} --import &>/dev/null
printf 'minimize\nquit\ny\n' | \
${GPG} --command-fd 0 --edit-key ${keyid}
${GPG} --yes --lsign-key ${keyid} &>/dev/null
@@ -44,8 +45,8 @@ ${GPG} --import-ownertrust < archlinux32-trusted 2>/dev/null
while read -ra data; do
keyid="${data[0]}"
${GPG} --recv-keys ${keyid} &>/dev/null
- gpg -a --export ${keyid} | ${GPG} --import &>/dev/null
- ssh buildmaster "gpg -a --export ${keyid}" | ${GPG} --import &>/dev/null
+ gpg ${GPG_OPTIONS} -a --export ${keyid} | ${GPG} --import &>/dev/null
+ ssh buildmaster "gpg ${GPG_OPTIONS} -a --export ${keyid}" | ${GPG} --import &>/dev/null
done < packager-keyids
while read -ra data; do
keyid="${data[0]}"
@@ -65,8 +66,8 @@ while read -ra data; do
keyid="${data[0]}"
username="${data[2]}"
${GPG} --recv-keys ${keyid} &>/dev/null
- gpg -a --export ${keyid} | ${GPG} --import &>/dev/null
- ssh buildmaster "gpg -a --export ${keyid}" | ${GPG} --import &>/dev/null
+ gpg ${GPG_OPTIONS} -a --export ${keyid} | ${GPG} --import &>/dev/null
+ ssh buildmaster "gpg ${GPG_OPTIONS} -a --export ${keyid}" | ${GPG} --import &>/dev/null
printf 'clean\nquit\ny\n' | \
${GPG} --command-fd 0 --edit-key ${keyid}
if ! ${GPG} --list-keys --with-colons ${keyid} 2>/dev/null | grep -q '^pub:f:'; then
@@ -81,8 +82,8 @@ while read -ra data; do
keyid="${data[0]}"
username="${data[2]}"
${GPG} --recv-keys ${keyid} &>/dev/null
- gpg -a --export ${keyid} | ${GPG} --import &>/dev/null
- ssh buildmaster "gpg -a --export ${keyid}" | ${GPG} --import &>/dev/null
+ gpg ${GPG_OPTIONS} -a --export ${keyid} | ${GPG} --import &>/dev/null
+ ssh buildmaster "gpg ${GPG_OPTIONS} -a --export ${keyid}" | ${GPG} --import &>/dev/null
printf 'clean\nquit\ny\n' | \
${GPG} --command-fd 0 --edit-key ${keyid}
if ! ${GPG} --list-keys --with-colons ${keyid} 2>/dev/null | grep -q '^pub:f:'; then