diff options
author | makefu <github@syntax-fehler.de> | 2023-04-23 16:26:01 +0200 |
---|---|---|
committer | makefu <github@syntax-fehler.de> | 2023-04-23 16:26:01 +0200 |
commit | 60fb7a1aa12b1d18224babeaf5481e43663b65b8 (patch) | |
tree | 2054d6460bc1a4a35de4496c88d33644878757da /kartei/trust-gpg.sh | |
parent | d8de7ad7063d6a2028e8dc40771f89af216fbfaf (diff) | |
parent | 4bf2909be3afb5e834cacdb4d6f949e4dd78400e (diff) |
Merge remote-tracking branch 'lassul.us/master'
Diffstat (limited to 'kartei/trust-gpg.sh')
-rwxr-xr-x | kartei/trust-gpg.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/kartei/trust-gpg.sh b/kartei/trust-gpg.sh new file mode 100755 index 000000000..84b67aeb4 --- /dev/null +++ b/kartei/trust-gpg.sh @@ -0,0 +1,13 @@ +#!/bin/sh +# usage: $0 +set -eu +WD=$(dirname "$(realpath "$0")") +PUBKEYS= +for key in "$WD"/kmein/kmein.gpg "$WD"/lass/pgp/* "$WD"/makefu/pgp/* "$WD"/tv/pgp/*; do + echo "$key" >&2 + keyid=$(gpg --with-colons --fingerprint --import-options show-only --import "$key" | grep fpr | cut -d : -f 10 | head -1) + gpg --import "$key" >&2 + printf '5\ny\n' | gpg --command-fd 0 --expert --edit-key "$keyid" trust >&2 + PUBKEYS="${PUBKEYS}${keyid}\n" +done +printf "$PUBKEYS" |