forked from RaindropViewer/RaindropViewer
-
Notifications
You must be signed in to change notification settings - Fork 0
69 lines (61 loc) · 2.03 KB
/
main.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
# Taking notes...
# https://github.com/modesttree/Zenject/blob/master/.github/workflows/main.yml
name: Test and build
on:
pull_request: {}
push: { branches: [main, develop] }
jobs:
buildAndTestForSupportedPlatforms:
name: Build for ${{ matrix.targetPlatform }} on version ${{ matrix.unityVersion }}
runs-on: ubuntu-latest
environment: SecondLife_1
strategy:
fail-fast: false
matrix:
unityVersion:
- 2020.3.29f1
targetPlatform:
- Android # Build a Android standalone.
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0
lfs: true
- name: Restore Library cache
uses: actions/cache@v2
with:
path: Library
key: Library-${{ matrix.targetPlatform }}
restore-keys: |
Library-
# Test
- name: Run tests
uses: alexiscatnip/unity-test-runner@main
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
USERNAME_SECONDLIFE: ${{ secrets.USERNAME_SECONDLIFE }}
PASSWORD_SECONDLIFE: ${{ secrets.PASSWORD_SECONDLIFE }}
GRIDFRIENDLYNAME_SECONDLIFE: ${{ secrets.GRIDFRIENDLYNAME_SECONDLIFE }}
with:
githubToken: ${{ secrets.GITHUB_TOKEN }}
unityVersion: ${{ matrix.unityVersion }}
# Build
- name: Build project
uses: game-ci/unity-builder@v2
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
with:
unityVersion: ${{ matrix.unityVersion }}
targetPlatform: ${{ matrix.targetPlatform }}
# https://github.com/RaindropViewer/RaindropViewer/issues/18
allowDirtyBuild: true
# Output
- uses: actions/upload-artifact@v2
with:
name: Build
path: build