forked from szwacz/electron-boilerplate
-
Notifications
You must be signed in to change notification settings - Fork 3
57 lines (50 loc) · 1.2 KB
/
electron.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
name: Electron test/build
on: [push]
jobs:
test:
runs-on: macOS-latest
steps:
- name: checkout
uses: actions/checkout@v1
- name: use Node.js 12.x
uses: actions/setup-node@v1
with:
node-version: 12.x
- name: install
run: yarn install
- name: tests
run: yarn test
env:
CI: true
build:
needs: test
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macOS-latest, windows-latest]
steps:
- name: checkout
uses: actions/checkout@v1
- name: use Node.js 12.x
uses: actions/setup-node@v1
with:
node-version: 12.x
- name: install
run: yarn install
- name: package
run: yarn package
- name: artifacts(mac)
if: matrix.os == 'macOS-latest'
run: |
mkdir artifacts
cp dist/*.dmg artifacts
- name: artifacts(win)
if: matrix.os == 'windows-latest'
run: |
mkdir artifacts
cp dist/*.exe artifacts
- name: Upload artifact
uses: actions/[email protected]
with:
name: ${{ matrix.os }}
path: artifacts