-
Notifications
You must be signed in to change notification settings - Fork 3
93 lines (88 loc) · 2.58 KB
/
ci.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
name: CI
on:
push:
branches:
- main
tags:
- "v*"
pull_request:
jobs:
build-macos-launcher:
name: build-macos-launcher ${{ matrix.OS }}
strategy:
fail-fast: false
matrix:
OS: ["macOS-m1", "macos-latest"]
include:
- OS: "macOS-m1"
JVM: "https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-22.1.0/graalvm-ce-java17-darwin-aarch64-22.1.0.tar.gz"
- OS: "macos-latest"
JVM: "https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-22.1.0/graalvm-ce-java17-darwin-amd64-22.1.0.tar.gz"
runs-on: ${{ matrix.OS }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
submodules: true
- uses: coursier/[email protected]
with:
apps: ""
jvm: ${{ matrix.JVM }}
- run: |
./mill -i "cs-m1.writeNativeImageScript" generate.sh "" && \
./generate.sh && \
./mill -i "cs-m1.copyToArtifacts" artifacts/
env:
GRAALVM_ID: ${{ matrix.JVM }}
- name: Build OS packages
if: matrix.os == 'macOS-m1'
run: .github/scripts/generate-os-packages.sh
shell: bash
- uses: actions/[email protected]
with:
name: macos-launcher
path: artifacts/
if-no-files-found: error
retention-days: 1
- name: Test
run: ./mill -i cs-m1-tests.test
build-linux-launcher:
runs-on: "macOS-m1"
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
submodules: true
- uses: coursier/[email protected]
with:
apps: ""
- run: .github/scripts/build-linux-aarch64.sh
- uses: actions/[email protected]
with:
name: linux-launcher
path: artifacts/
if-no-files-found: error
retention-days: 1
- run: .github/scripts/test-linux-aarch64.sh
upload-artifacts:
if: github.event_name == 'push'
runs-on: "ubuntu-latest"
needs: ["build-macos-launcher", "build-linux-launcher"]
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
submodules: true
- name: Get macOS launchers
uses: actions/download-artifact@v3
with:
name: macos-launcher
path: artifacts/
- name: Get Linux launcher
uses: actions/download-artifact@v3
with:
name: linux-launcher
path: artifacts/
- run: ./mill -i ci.upload artifacts/
env:
UPLOAD_GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}