Publish Release #45
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish Release | |
on: | |
workflow_dispatch: | |
env: | |
GITHUB_TOKEN: ${{ secrets.BANNO_AUTOBOT_GITHUB_TOKEN }} | |
jobs: | |
release: | |
name: Publish Release | |
runs-on: ubuntu-latest | |
timeout-minutes: 10 | |
steps: | |
- uses: actions/setup-java@v4 | |
with: | |
distribution: 'zulu' | |
java-version: 21 | |
- uses: gradle/actions/setup-gradle@v4 | |
- uses: actions/checkout@v4 | |
with: | |
token: ${{ env.GITHUB_TOKEN }} | |
- id: current_version | |
uses: christian-draeger/[email protected] | |
with: | |
path: gordon-plugin/gradle.properties | |
properties: version | |
- name: Create Tag | |
run: | | |
git config user.name github-actions | |
git config user.email [email protected] | |
git tag -a ${{ steps.current_version.outputs.version }} -m ${{ steps.current_version.outputs.version }} | |
git push origin ${{ steps.current_version.outputs.version }} | |
- name: Create Release | |
uses: ncipollo/release-action@v1 | |
with: | |
tag: ${{ steps.current_version.outputs.version }} | |
generateReleaseNotes: true | |
makeLatest: true | |
- name: Gradle Publish | |
env: | |
GRADLE_PLUGIN_PUBLISH_KEY: ${{ secrets.GRADLE_PLUGIN_PUBLISH_KEY }} | |
GRADLE_PLUGIN_PUBLISH_SECRET: ${{ secrets.GRADLE_PLUGIN_PUBLISH_SECRET }} | |
run: ./gradlew publishPlugins | |
- id: next_version | |
uses: christian-draeger/[email protected] | |
with: | |
current-version: ${{ steps.current_version.outputs.version }} | |
version-fragment: bug | |
- name: Bump Version | |
uses: christian-draeger/[email protected] | |
with: | |
path: gordon-plugin/gradle.properties | |
property: version | |
value: ${{ steps.next_version.outputs.next-version }} | |
- name: Commit Version Bump | |
run: | | |
git config user.name github-actions | |
git config user.email [email protected] | |
git add gordon-plugin/gradle.properties | |
git commit -m "Bump version to ${{ steps.next_version.outputs.next-version }}" | |
git push |