-
Notifications
You must be signed in to change notification settings - Fork 1
50 lines (49 loc) · 1.49 KB
/
java-sdk.yaml
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
name: Build Java SDK Jars
on:
workflow_dispatch: {}
label:
types:
- created
jobs:
build-java-sdk:
name: Build Java SDK
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Download Latest Native Library
uses: dawidd6/action-download-artifact@v2
with:
github_token: ${{secrets.GITHUB_TOKEN}}
workflow: unity-plugin-zip.yaml
workflow_conclusion: success
path: artifacts
- name: Copy Native Library to Java Project
run: |
mkdir -p output/lib
cp artifacts/libreddio-x86_64-pc-windows-msvc/reddio.dll output/lib/reddio.dll
cp artifacts/libreddio-x86_64-apple-darwin/libreddio.dylib output/lib/libreddio.dylib
cp artifacts/libreddio-x86_64-unknown-linux-gnu/libreddio.so output/lib/libreddio.so
ls -alh output/lib
- name: Setup Java
uses: actions/setup-java@v3
with:
distribution: "adopt"
java-version: "8"
- name: Cache Maven
uses: actions/cache@v3
with:
path: |
~/.m2
~/repository
key: ${{ github.job }}-${{ hashFiles('**/pom.xml') }}
- name: Build Java SDK Jars
working-directory: reddio-java
run: |
mvn -B clean verify -DskipTests
- name: Upload Jars
uses: actions/upload-artifact@v3
with:
name: reddio-java-sdk
path: |
reddio-java/**/*.jar