From 7185e3e4e6ce33881ed254e0c6c2d1f26d13b5d6 Mon Sep 17 00:00:00 2001 From: Paul Campbell Date: Sun, 21 Jun 2020 08:56:49 +0100 Subject: [PATCH] Use automatic-releases github action (#466) * maven-build creates dev-build release * Delete release-drafter.yml * Delete release-drafter.yml * sonatype-deploy creates release for v* tags --- .github/release-drafter.yml | 32 --------------------------- .github/workflows/maven-build.yml | 8 +++++++ .github/workflows/release-drafter.yml | 14 ------------ .github/workflows/sonatype-deploy.yml | 12 ++++++++-- 4 files changed, 18 insertions(+), 48 deletions(-) delete mode 100644 .github/release-drafter.yml delete mode 100644 .github/workflows/release-drafter.yml diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml deleted file mode 100644 index f90b685..0000000 --- a/.github/release-drafter.yml +++ /dev/null @@ -1,32 +0,0 @@ -name-template: 'v$RESOLVED_VERSION 🌈' -tag-template: 'v$RESOLVED_VERSION' -categories: - - title: '🚀 Features' - labels: - - 'feature' - - 'enhancement' - - title: '🐛 Bug Fixes' - labels: - - 'fix' - - 'bugfix' - - 'bug' - - title: '🧰 Maintenance' - labels: - - 'chore' - - 'dependencies' -change-template: '- $TITLE @$AUTHOR (#$NUMBER)' -version-resolver: - major: - labels: - - 'major' - minor: - labels: - - 'minor' - patch: - labels: - - 'patch' - default: patch -template: | - ## Changes - - $CHANGES diff --git a/.github/workflows/maven-build.yml b/.github/workflows/maven-build.yml index 1a7bdd6..fbffc0b 100644 --- a/.github/workflows/maven-build.yml +++ b/.github/workflows/maven-build.yml @@ -24,3 +24,11 @@ jobs: java-version: ${{ matrix.java }} - name: build-jar run: mvn -B install + - uses: "marvinpinto/action-automatic-releases@latest" + with: + repo_token: "${{ secrets.GITHUB_TOKEN }}" + automatic_release_tag: "latest" + prerelease: true + title: "Development Build" + files: | + app/target/thorp-*.jar diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml deleted file mode 100644 index 17fdb96..0000000 --- a/.github/workflows/release-drafter.yml +++ /dev/null @@ -1,14 +0,0 @@ -name: Release Drafter - -on: - push: - branches: - - master - -jobs: - update_release_draft: - runs-on: ubuntu-latest - steps: - - uses: release-drafter/release-drafter@v5 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/sonatype-deploy.yml b/.github/workflows/sonatype-deploy.yml index 31a47c4..34a02f7 100644 --- a/.github/workflows/sonatype-deploy.yml +++ b/.github/workflows/sonatype-deploy.yml @@ -1,8 +1,9 @@ name: sonatype-deploy on: - release: - types: [published] + push: + tags: + - "v*" jobs: deploy: @@ -37,3 +38,10 @@ jobs: NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }} GPG_KEYNAME: ${{ secrets.GPG_KEYNAME }} GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} + - uses: "marvinpinto/action-automatic-releases@latest" + with: + repo_token: "${{ secrets.GITHUB_TOKEN }}" + automatic_release_tag: "latest" + prerelease: false + files: | + app/target/thorp-*.jar