1
1
name : Build
2
- on : [push, pull_request]
2
+ on : [ push, pull_request ]
3
3
4
- jobs :
5
- build-win-x64 :
6
- runs-on : windows-latest
7
- steps :
8
- - uses : actions/checkout@v2
9
- - uses : actions/setup-dotnet@v1
10
- with :
11
- dotnet-version : ' 3.1.x'
12
- - name : Build
13
- run : |
14
- cd VisualPinball.Engine.Mpf
15
- dotnet build -c Release -r win-x64
16
- # - name: Test
17
- # run: |
18
- # cd VisualPinball.Engine.Mpf.Test
19
- # dotnet run -c Release -r win-x64
20
- - run : |
21
- mkdir tmp
22
- xcopy /E /I VisualPinball.Engine.Mpf.Unity\Plugins\win-x64 tmp\win-x64
23
- - uses : actions/upload-artifact@v2
24
- with :
25
- name : Plugins
26
- path : tmp
27
-
28
- build-win-x86 :
29
- runs-on : windows-latest
30
- steps :
31
- - uses : actions/checkout@v2
32
- - uses : actions/setup-dotnet@v1
33
- with :
34
- dotnet-version : ' 3.1.x'
35
- - name : Build
36
- run : |
37
- cd VisualPinball.Engine.Mpf
38
- dotnet build -c Release -r win-x86
39
- # - name: Test
40
- # run: |
41
- # cd VisualPinball.Engine.Mpf.Test
42
- # dotnet run -c Release -r win-x86
43
- - run : |
44
- mkdir tmp
45
- xcopy /E /I VisualPinball.Engine.Mpf.Unity\Plugins\win-x86 tmp\win-x86
46
- - uses : actions/upload-artifact@v2
47
- with :
48
- name : Plugins
49
- path : tmp
50
-
51
- build-osx-x64 :
52
- runs-on : macos-latest
53
- steps :
54
- - uses : actions/checkout@v2
55
- - uses : actions/setup-dotnet@v1
56
- with :
57
- dotnet-version : ' 3.1.x'
58
- - name : Build
59
- run : |
60
- cd VisualPinball.Engine.Mpf
61
- dotnet build -c Release -r osx-x64
62
- # - name: Test
63
- # run: |
64
- # cd VisualPinball.Engine.Mpf.Test
65
- # dotnet run -c Release -r osx-x64
66
- - run : |
67
- mkdir tmp
68
- cp -r VisualPinball.Engine.Mpf.Unity/Plugins/osx-x64 tmp
69
- - uses : actions/upload-artifact@v2
70
- with :
71
- name : Plugins
72
- path : tmp
4
+ defaults :
5
+ run :
6
+ shell : bash
73
7
74
- build-linux-x64 :
75
- runs-on : ubuntu-latest
8
+ jobs :
9
+ build :
10
+ name : Build ${{ matrix.rid }}
11
+ runs-on : ${{ matrix.os }}
12
+ strategy :
13
+ fail-fast : false
14
+ matrix :
15
+ include :
16
+ - os : windows-latest
17
+ rid : win-x64
18
+ - os : windows-latest
19
+ rid : win-x86
20
+ - os : macos-latest
21
+ rid : osx-x64
22
+ - os : ubuntu-latest
23
+ rid : linux-x64
76
24
steps :
77
25
- uses : actions/checkout@v2
78
26
- uses : actions/setup-dotnet@v1
@@ -81,22 +29,22 @@ jobs:
81
29
- name : Build
82
30
run : |
83
31
cd VisualPinball.Engine.Mpf
84
- dotnet build -c Release -r linux-x64
32
+ dotnet build -c Release -r ${{ matrix.rid }}
85
33
# - name: Test
86
34
# run: |
87
35
# cd VisualPinball.Engine.Mpf.Test
88
- # dotnet run -c Release -r linux-x64
36
+ # dotnet run -c Release -r ${{ matrix.rid }}
89
37
- run : |
90
38
mkdir tmp
91
- cp -r VisualPinball.Engine.Mpf.Unity/Plugins/linux-x64 tmp
39
+ cp -r VisualPinball.Engine.Mpf.Unity/Plugins/${{ matrix.rid }} tmp
92
40
- uses : actions/upload-artifact@v2
93
41
with :
94
42
name : Plugins
95
43
path : tmp
96
44
97
45
dispatch :
98
46
runs-on : ubuntu-latest
99
- needs : [ build-win-x64, build-win-x86, build-osx-x64, build-linux-x64 ]
47
+ needs : [ build ]
100
48
if : github.repository == 'VisualPinball/VisualPinball.Engine.Mpf' && github.ref == 'refs/heads/master' && github.event_name == 'push'
101
49
steps :
102
50
- uses : peter-evans/repository-dispatch@v1
0 commit comments