update README #3
Workflow file for this run
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: CI Pipeline | |
on: | |
pull_request: | |
branches: | |
- master | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
name: Build with Gradle | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
- name: Set up JDK 21 | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'temurin' | |
java-version: '21' | |
- name: Grant execute permission for Gradle | |
run: chmod +x gradlew | |
- name: Build the project | |
run: ./gradlew build | |
publish: | |
name: Publish to GitHub Packages | |
runs-on: ubuntu-latest | |
needs: build | |
if: github.ref == 'refs/heads/master' | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
- name: Set up JDK 21 | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'temurin' | |
java-version: '21' | |
- name: Grant execute permission for Gradle | |
run: chmod +x gradlew | |
- name: Publish to GitHub Packages | |
run: ./gradlew publish | |
env: | |
GPR_USER: ${{ secrets.GPR_USER }} | |
GPR_TOKEN: ${{ secrets.GPR_TOKEN }} |