Update parser.kt #13
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: Build Project | |
on: | |
push: | |
branches: [ master, ver/* ] | |
pull_request: | |
branches: [ master, ver/* ] | |
workflow_dispatch: | |
jobs: | |
setup: | |
runs-on: ubuntu-latest | |
timeout-minutes: 20 | |
name: Gradle Setup | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
- uses: gradle/actions/wrapper-validation@v3 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'temurin' | |
java-version: '11' | |
cache: 'gradle' | |
- name: Change Permissions | |
run: chmod +x ./gradlew | |
- name: Gradle Information | |
run: ./gradlew project tasks dependencies | |
build: | |
runs-on: ubuntu-latest | |
needs: setup | |
timeout-minutes: 10 | |
strategy: | |
matrix: | |
java-version: [11, 17, 21] | |
name: Build Java ${{ matrix.java-version }} | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
- name: Set up JDK ${{ matrix.java-version }} | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'temurin' | |
java-version: ${{ matrix.java-version }} | |
cache: 'gradle' | |
- name: Change Permissions | |
run: chmod +x ./gradlew | |
- name: Build with Gradle | |
run: ./gradlew clean assemble publishToMavenLocal | |
test: | |
runs-on: ubuntu-latest | |
timeout-minutes: 10 | |
needs: setup | |
name: Test Project | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
- name: Setup JDK 11 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '11' | |
distribution: 'temurin' | |
cache: 'gradle' | |
- name: Change Permissions | |
run: chmod +x ./gradlew | |
- name: Gradle Test | |
run: ./gradlew clean test | |
deploy: | |
runs-on: ubuntu-latest | |
needs: [build, test] | |
name: Deploy Dokka | |
if: ${{ github.event_name != 'pull_request' && github.ref_name == 'master' }} | |
timeout-minutes: 30 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'temurin' | |
java-version: '17' | |
cache: 'gradle' | |
- name: Change Permissions | |
run: chmod +x ./gradlew | |
- name: Build Dokka | |
run: ./gradlew clean dokkaHtml | |
- name: Deploy Dokka | |
run: bash dokka.sh ${GITHUB_SHA::7} | |
publish: | |
runs-on: ubuntu-latest | |
needs: build | |
name: Publish to Repository | |
timeout-minutes: 30 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'temurin' | |
java-version: '11' | |
cache: 'gradle' | |
- name: Change Permissions | |
run: chmod +x ./gradlew | |
- name: Publish to Repository | |
env: | |
NEXUS_USERNAME: ${{ secrets.NEXUS_USERNAME }} | |
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }} | |
run: ./gradlew clean build publish -x test |