Skip to content

Commit 47d5b18

Browse files
author
Martin Harris
committed
Adds support for both gpg and gpg2 when verifying
1 parent 9a9090a commit 47d5b18

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

developers/committers/release-process/verify-release-artifacts.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,16 @@ Verify the hashes and signatures of artifacts
9898
Then check the hashes and signatures, ensuring you get a positive message from each one:
9999

100100
{% highlight bash %}
101+
GPG_COMMAND=$((which gpg >> /dev/null && echo gpg) || (which gpg2 >> /dev/null && echo gpg2))
102+
103+
if [ -z "${GPG_COMMAND}" ]; then
104+
echo "gpg or gpg2 must be installed, exiting"
105+
exit
106+
fi
107+
101108
for artifact in $(find * -type f ! \( -name '*.asc' -o -name '*.sha256' \) ); do
102109
shasum -a256 -c ${artifact}.sha256 && \
103-
gpg2 --verify ${artifact}.asc ${artifact} \
110+
$GPG_COMMAND --verify ${artifact}.asc ${artifact} \
104111
|| { echo "Invalid signature for $artifact. Aborting!"; break; }
105112
done
106113
{% endhighlight %}

0 commit comments

Comments
 (0)