From 21c965405393802232773d857064108b29cb0940 Mon Sep 17 00:00:00 2001 From: Allen Wittenauer Date: Sat, 11 Nov 2023 13:50:09 -0800 Subject: [PATCH] YETUS-1238. Add code to test gpg signing in initial-patches --- release/initial-patches.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/release/initial-patches.sh b/release/initial-patches.sh index e1db79fc..f31366c8 100755 --- a/release/initial-patches.sh +++ b/release/initial-patches.sh @@ -145,12 +145,24 @@ update_version() { git add "${BASEDIR}/.mvn/maven.config" } +test_gpg_signing() { + declare binary + echo "**** testing gpg signing" + binary=$(git config gpg.program) + if ! echo "test" | "${binary}" -o /dev/null -as -; then + exit 1 + fi + +} + option_parse "$@" check_basedir_repo trap cleanup INT QUIT TRAP ABRT BUS SEGV TERM ERR +test_gpg_signing + set -x git clean -xdf