Manual #1
This file contains hidden or 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: Build Development | |
| on: | |
| push: | |
| branches: [main] | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| build-and-release: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: Set up JDK 24 | |
| uses: actions/setup-java@v5 | |
| with: | |
| java-version: '24' | |
| distribution: 'temurin' | |
| - name: Cache Maven dependencies | |
| uses: actions/cache@v5 | |
| with: | |
| path: ~/.m2 | |
| key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} | |
| restore-keys: ${{ runner.os }}-m2 | |
| - name: Build with Maven | |
| run: mvn clean package -DskipTests | |
| - name: Extract repository name | |
| run: echo "NAME=$(basename ${{ github.repository }})" >> $GITHUB_ENV | |
| - name: Upload Build | |
| uses: marvinpinto/action-automatic-releases@master | |
| with: | |
| title: "${{ env.NAME }}" | |
| automatic_release_tag: "latest" | |
| repo_token: "${{ secrets.GITHUB_TOKEN }}" | |
| files: "target/*.jar" | |
| prerelease: false |