From 99292917314bb4291e32e7f0859709e0e2e43edf Mon Sep 17 00:00:00 2001 From: Allen Wittenauer Date: Mon, 13 Nov 2023 11:50:40 -0800 Subject: [PATCH] YETUS-1238. Add code to test gpg signing in initial-patches (#327) Signed-off-by: Nick Dimiduk --- release/initial-patches.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/release/initial-patches.sh b/release/initial-patches.sh index 05cbb00e..5f71452b 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