File tree Expand file tree Collapse file tree 1 file changed +61
-6
lines changed Expand file tree Collapse file tree 1 file changed +61
-6
lines changed Original file line number Diff line number Diff line change 6
6
name : Release
7
7
8
8
jobs :
9
- build :
10
- name : Release
9
+ ubuntu- build :
10
+ name : Ubuntu build
11
11
runs-on : ubuntu-latest
12
12
steps :
13
13
@@ -26,15 +26,70 @@ jobs:
26
26
- name : Checkout code
27
27
uses : actions/checkout@v2
28
28
29
- - name : Set output
30
- id : vars
31
- run : echo ::set-output name=tag::${GITHUB_REF#refs/*/}
32
-
33
29
- name : Build project
34
30
run : |
35
31
chmod +x build.sh
36
32
./build.sh
37
33
34
+ - name : Upload
35
+ uses : actions/upload-artifact@v2
36
+ with :
37
+ name : my-artifact
38
+ path : |
39
+ ./build/*.zip
40
+ !./build/*_windows_amd64.zip
41
+
42
+ windows-build :
43
+ name : Windows build
44
+ runs-on : windows-latest
45
+ steps :
46
+
47
+ - name : Set up upx
48
+ run : choco install upx
49
+
50
+ - name : Set up Go 1.x
51
+ uses : actions/setup-go@v2
52
+ with :
53
+ go-version : ^1.16
54
+ id : go
55
+
56
+ - name : Set up node 14.x
57
+ uses : actions/setup-node@v2
58
+ with :
59
+ node-version : 14.x
60
+ id : node
61
+
62
+ - name : Checkout code
63
+ uses : actions/checkout@v2
64
+
65
+ - name : Build project
66
+ run : .\build.ps1
67
+
68
+ - name : Upload
69
+ uses : actions/upload-artifact@v2
70
+ with :
71
+ name : my-artifact
72
+ path : .\build\*_windows_amd64.zip
73
+
74
+ release :
75
+ name : Release
76
+ needs : [ubuntu-build, windows-build]
77
+ runs-on : ubuntu-latest
78
+ steps :
79
+
80
+ - name : Checkout code
81
+ uses : actions/checkout@v2
82
+
83
+ - name : Set output
84
+ id : vars
85
+ run : echo ::set-output name=tag::${GITHUB_REF#refs/*/}
86
+
87
+ - name : Download
88
+ uses : actions/download-artifact@v2
89
+ with :
90
+ name : my-artifact
91
+ path : ./build/
92
+
38
93
- name : Release
39
94
uses : softprops/action-gh-release@v1
40
95
if : startsWith(github.ref, 'refs/tags/')
You can’t perform that action at this time.
0 commit comments