-
Notifications
You must be signed in to change notification settings - Fork 146
71 lines (68 loc) · 2.22 KB
/
Copy pathbuild.yml
File metadata and controls
71 lines (68 loc) · 2.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: Build
on:
push:
branches:
- main
permissions:
checks: write
contents: write
concurrency:
group: ${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
gradle:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
with:
fetch-depth: 0
fetch-tags: true
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '21'
- name: Cache SonarCloud packages
uses: actions/cache@v4
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v5
- name: Run Gradle Build
run: ./gradlew check publish sonar
env:
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ vars.OSSRH_USERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.OSSRH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
- name: Publish Test Report
uses: mikepenz/action-junit-report@v5
if: success() || failure() # always run even if the previous step fails
with:
report_paths: '**/build/test-results/test/TEST-*.xml'
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v5
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Compile engine-js for the CQL playground
run: ./gradlew engine:compileProductionLibraryKotlinJs engine:compileProductionLibraryKotlinWasmJs
- name: Install Node.js
uses: actions/setup-node@v5
with:
node-version: '24'
package-manager-cache: false
- name: Install playground dependencies
working-directory: ./js/cql-to-elm-ui
run: npm ci --ignore-scripts
- name: Build and export playground
working-directory: ./js/cql-to-elm-ui
run: npm run build
- name: Add .nojekyll
run: touch ./js/cql-to-elm-ui/out/.nojekyll
- name: Deploy playground to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./js/cql-to-elm-ui/out
destination_dir: playground