Skip to content

feat(ci): Polish

feat(ci): Polish #71

Workflow file for this run

name: CI
on:
push:
branches:
- main
tags-ignore:
- heo-*
pull_request:
jobs:
ci:
permissions:
pull-requests: write
strategy:
matrix:
os: [ macos-12, ubuntu-latest ]
version: [ 17, 21 ]
runs-on: ${{ matrix.os }}
name: build-${{ matrix.os }}-jdk-${{ matrix.version }}
steps:
- uses: actions/checkout@v4
- name: Set up JDK
uses: graalvm/setup-graalvm@v1
with:
java-version: ${{ matrix.version }}
distribution: 'graalvm'
- name: Check Gradle Version
run: |
chmod +x gradlew
./gradlew --version
- name: Setup Graphviz
uses: ts-graphviz/setup-graphviz@v2
- name: Test
run: |
./gradlew --parallel --max-workers=4 build
- name: Plugin Test
run: |
./gradlew :heo-gradle-plugin:publishToMavenLocal
./gradlew -PlocalPlugin :it:gradle-plugin:heoReport
- name: Create self report file
if: success()
run: |
JAR_FILE=$(ls -al ./heo-cli/build/libs/ | tail -1 | awk '{print $9}')
java -jar ./heo-cli/build/libs/$JAR_FILE \
-d $(pwd) \
-p dev.heowc.heo.core \
-o interg-report.png
- name: Upload self report file
if: success() && github.event.pull_request.number != ''
uses: actions/upload-artifact@v4
with:
path: interg-report.png
name: interg-reports-${{ github.event.pull_request.number }}-${{ github.run_id }}-${{ matrix.os }}-jdk-${{ matrix.version }}
retention-days: 7
- name: If failure then upload test reports
if: failure()
uses: actions/upload-artifact@v4
with:
path: '*/build/reports/tests'
name: test-reports
retention-days: 7