Updating Build #24
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: Java CI | |
on: | |
push: | |
branches: | |
- '[6-9]+.[0-9]+.x' | |
pull_request: | |
branches: | |
- '[6-9]+.[0-9]+.x' | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
WORKSPACE: ${{ github.workspace }} | |
GRADLE_OPTS: -Xmx1500m -Dfile.encoding=UTF-8 | |
SIGNING_KEYRING: ${{ secrets.SECRING_FILE }} | |
steps: | |
- name: "📥 Checkout the repository" | |
uses: actions/checkout@v4 | |
- name: "🧱 Setup up node" | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '20.5.1' | |
- name: "Pull node dependencies" | |
run: npm install | |
- name: "Package node dependencies" | |
run: npx gulp grailsRelease | |
- name: "☕️ Setup JDK" | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'liberica' | |
java-version: '17' | |
- name: "🐘 Setup Gradle" | |
uses: gradle/actions/setup-gradle@v4 | |
- name: "🔨 Run Base Tests" | |
run: ./gradlew check --continue | |
publish: | |
if: github.event_name == 'push' | |
needs: build | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
steps: | |
- name: "📥 Checkout the repository" | |
uses: actions/checkout@v4 | |
- name: "🧱 Setup up node" | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '20.5.1' | |
- name: "Pull node dependencies" | |
run: npm install | |
- name: "Package node dependencies" | |
run: npx gulp grailsRelease | |
- name: "☕️ Setup JDK" | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'liberica' | |
java-version: '17' | |
- name: "🐘 Setup Gradle" | |
uses: gradle/actions/setup-gradle@v4 | |
- name: "📤 Publish to Snapshot (repo.grails.org)" | |
env: | |
MAVEN_PUBLISH_USERNAME: ${{ secrets.MAVEN_PUBLISH_USERNAME }} | |
MAVEN_PUBLISH_PASSWORD: ${{ secrets.MAVEN_PUBLISH_PASSWORD }} | |
MAVEN_PUBLISH_URL: ${{ secrets.MAVEN_PUBLISH_SNAPSHOT_URL }} | |
working-directory: ./plugin | |
run: ../gradlew publish |