-
Notifications
You must be signed in to change notification settings - Fork 0
105 lines (100 loc) · 3.12 KB
/
scala.yml
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
name: Baboon Build
on:
push:
branches: [ "main" ]
tags:
- "v*.*.*"
pull_request:
branches: [ "main" ]
permissions:
contents: write
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest, macos-latest, windows-2022 ]
graalvm-version: [ '22.3.1' ]
java-version: [ '17' ]
include:
- os: ubuntu-latest
executable-suffix: ''
native-build-args: --verbose -J-Xmx10g
- os: macos-latest
executable-suffix: ''
native-build-args: --verbose -J-Xmx13g
- os: windows-2022
executable-suffix: '.exe'
# e2e is disabled due to unstable docker step
#e2e: false
native-build-args: --verbose -J-Xmx10g
steps:
- uses: actions/checkout@v3
- name: Set up GraalVM (Java ${{ matrix.java-version }})
uses: graalvm/setup-graalvm@v1
with:
version: '${{ matrix.graalvm-version }}'
java-version: '${{ matrix.java-version }}'
distribution: 'graalvm-community'
components: 'native-image'
github-token: ${{ secrets.GITHUB_TOKEN }}
cache: 'sbt'
native-image-job-reports: true
- name: Run tests
run: sbt test
- name: Build NI
run: sbt GraalVMNativeImage/packageBin
- uses: actions/upload-artifact@v3
with:
name: native-image-${{ matrix.os }}
path: |
target/graalvm-native-image/**
- name: Run test build
shell: bash
run: |
target/graalvm-native-image/baboon \
--model-dir ./src/test/resources/baboon/ \
--output ./test/cs-stub/ConversionsTest/Generated
cd ./test/cs-stub
dotnet build
prepare-release:
runs-on: ubuntu-latest
needs: [ build ]
steps:
- uses: actions/checkout@v1
- uses: actions/download-artifact@v3
with:
name: native-image-ubuntu-latest
path: tmp/baboon-linux-x64
- uses: actions/download-artifact@v3
with:
name: native-image-macos-latest
path: tmp/baboon-mac-x64
- uses: actions/download-artifact@v3
with:
name: native-image-windows-2022
path: tmp/baboon-windows-x64
- name: Prepare layout
run: |
pushd .
cd tmp/
zip -r9 baboon-linux-x64.zip ./baboon-linux-x64/
zip -r9 baboon-mac-x64.zip ./baboon-mac-x64/
zip -r9 baboon-windows-x64.zip ./baboon-windows-x64/
popd
mkdir dist
mv ./tmp/baboon-linux-x64/baboon dist/baboon-linux-x64
mv ./tmp/baboon-mac-x64/baboon dist/baboon-mac-x64
mv ./tmp/baboon-windows-x64/baboon.exe dist/baboon-x64.exe
mkdir dist-zip
mv ./tmp/baboon-linux-x64.zip ./dist-zip/
mv ./tmp/baboon-mac-x64.zip ./dist-zip/
mv ./tmp/baboon-windows-x64.zip ./dist-zip/
- uses: softprops/action-gh-release@v1
id: create-release
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
dist/**
dist-zip/**