build(deps): bump org.codehaus.mojo:versions-maven-plugin #109
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: Early Access | |
on: | |
push: | |
paths-ignore: | |
- '**.md' | |
- '.github/workflows/release.yml' | |
- '.github/dependabot.yml' | |
env: | |
JAVA_VERSION: '17' | |
JAVA_DISTRO: 'temurin' | |
jobs: | |
precheck: | |
if: startsWith(github.event.head_commit.message, 'Releasing version') != true | |
runs-on: ubuntu-latest | |
outputs: | |
VERSION: ${{ steps.vars.outputs.VERSION }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Cancel previous run | |
uses: styfle/[email protected] | |
with: | |
access_token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Setup Java | |
uses: actions/setup-java@v4 | |
with: | |
java-version: ${{ env.JAVA_VERSION }} | |
distribution: ${{ env.JAVA_DISTRO }} | |
- name: Cache local Maven repository | |
uses: actions/cache@v4 | |
with: | |
path: ~/.m2/repository | |
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | |
- name: Version | |
id: vars | |
shell: bash | |
run: | | |
VERSION=$(./mvnw help:evaluate -Dexpression=project.version -q -DforceStdout) | |
echo "VERSION=$(echo $VERSION)" >> $GITHUB_OUTPUT | |
assemble: | |
needs: [ precheck ] | |
if: endsWith(${{ needs.precheck.outputs.VERSION }}, '-SNAPSHOT') && ${{ github.ref == 'refs/heads/main' }} | |
uses: jagodevreede/sdkman-ui/.github/workflows/assemble-native.yml@main | |
with: | |
project-version: ${{ needs.precheck.outputs.VERSION }} | |
release-early-access: | |
needs: [ precheck, assemble ] | |
if: endsWith(${{ needs.precheck.outputs.VERSION }}, '-SNAPSHOT') | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Download artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
pattern: artifacts-* | |
merge-multiple: true | |
path: sdkman-ui/target/ | |
- name: Release | |
uses: jreleaser/release-action@v2 | |
with: | |
arguments: full-release | |
env: | |
JRELEASER_PROJECT_VERSION: ${{ needs.precheck.outputs.VERSION }} | |
JRELEASER_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: JReleaser output | |
if: always() | |
uses: actions/upload-artifact@v4 | |
with: | |
retention-days: 1 | |
name: jreleaser-release | |
path: | | |
out/jreleaser/trace.log | |
out/jreleaser/output.properties |