File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Build and release
2+
3+ on :
4+ push :
5+ branches :
6+ - build/**
7+ tags :
8+ - ' *'
9+
10+ jobs :
11+ build :
12+ runs-on : ${{ matrix.os }}
13+
14+ strategy :
15+ matrix :
16+ os : [macos-latest, ubuntu-latest, windows-latest]
17+ include :
18+ - os : macos-latest
19+ build : macos
20+ - os : ubuntu-latest
21+ build : linux
22+ - os : windows-latest
23+ build : windows
24+
25+ steps :
26+ - uses : actions/checkout@v2
27+
28+ - name : Setup Java JDK
29+ uses : actions/setup-java@v1.3.0
30+ with :
31+ java-version : 7
32+
33+ - name : Setup Python
34+ uses : actions/setup-python@v2
35+ with :
36+ python-version : 2.7
37+
38+ - name : Install Node.js
39+ uses : actions/setup-node@v1
40+ with :
41+ node-version : 13
42+ - name : Install npm packages
43+ run : npm install
44+
45+ - name : Compile scripts
46+ run : npm run compile:prod
47+
48+ - name : Build ${{ matrix.build }}
49+ run : npm run build:${{ matrix.build }}
50+
51+ - name : Upload to artifact if not tagged
52+ uses : actions/upload-artifact@v2
53+ if : " !startsWith(github.ref, 'refs/tags')"
54+ with :
55+ name : ${{ matrix.build }}
56+ path : builds/*.zip
57+
58+ - name : Release if tagged
59+ uses : softprops/action-gh-release@v1
60+ if : startsWith(github.ref, 'refs/tags/')
61+ with :
62+ files : builds/*.zip
63+ env :
64+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments