diff --git a/.azure/scripts/push-to-nexus.sh b/.azure/scripts/push-to-nexus.sh index f96722c7..771569ba 100755 --- a/.azure/scripts/push-to-nexus.sh +++ b/.azure/scripts/push-to-nexus.sh @@ -1,16 +1,23 @@ #!/usr/bin/env bash +set -e + echo "Build reason: ${BUILD_REASON}" echo "Source branch: ${BRANCH}" -GPG_TTY=$(tty) -export GPG_TTY +function cleanup() { + rm -rf signing.gpg + gpg --delete-keys + gpg --delete-secret-keys +} + +# Run the cleanup on failure / exit +trap cleanup EXIT -echo "$GPG_SIGNING_KEY" | base64 -d > signing.gpg +export GPG_TTY=$(tty) +echo $GPG_SIGNING_KEY | base64 -d > signing.gpg gpg --batch --import signing.gpg GPG_EXECUTABLE=gpg mvn $MVN_ARGS -DskipTests -s ./.azure/scripts/settings.xml -P ossrh verify deploy -rm -rf signing.gpg -gpg --delete-keys -gpg --delete-secret-keys \ No newline at end of file +cleanup \ No newline at end of file diff --git a/pom.xml b/pom.xml index b030ae86..814475bb 100644 --- a/pom.xml +++ b/pom.xml @@ -119,7 +119,7 @@ 3.2.1 3.3.0 3.0.1 - 1.6.7 + 1.7.0 1.3.7 1.3.4 2.16.1