diff --git a/.github/workflows/gradle-ci-publish.yml b/.github/workflows/gradle-ci-publish.yml index 20f6f4b..c297fa6 100644 --- a/.github/workflows/gradle-ci-publish.yml +++ b/.github/workflows/gradle-ci-publish.yml @@ -1,9 +1,9 @@ name: publish on: - release: - types: - - published + push: + tags: + - 'v*' jobs: publish: @@ -17,7 +17,8 @@ jobs: - name: Prepare to publish run: | - echo '${{secrets.GPG_KEY_CONTENTS}}' | base64 -d > secret.gpg + gpg --quiet --batch --yes --decrypt --passphrase="${{secrets.SECRET_PASSPHRASE}}" \ + --output secret.gpg publish_key.gpg echo "::set-env name=RELEASE_VERSION::${GITHUB_REF:11}" - name: Publish with Gradle diff --git a/publish_key.gpg b/publish_key.gpg new file mode 100644 index 0000000..3bd29a5 Binary files /dev/null and b/publish_key.gpg differ