-
-
Notifications
You must be signed in to change notification settings - Fork 101
75 lines (61 loc) · 2.25 KB
/
release.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
70
71
72
73
74
75
name: Release
on:
push:
branches:
- "main"
workflow_dispatch:
jobs:
publish:
name: "Publish"
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, ubuntu-latest]
steps:
- name: Check out Git repository
uses: actions/checkout@v2
- name: Install Node.js and NPM
uses: actions/setup-node@master
with:
node-version: 18
- name: Install dependencies
# npm ci is better, but requires package-lock.json file
run: npm install
# - name: Install dmg-license
# if: startsWith(matrix.os, 'macos')
# run: npm i dmg-license
- name: Build app
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CSC_LINK: ${{ secrets.CSC_LINK }}
CSC_KEY_PASSWORD: ${{ secrets.CSC_KEY_PASSWORD }}
GA_SECRET: ${{ secrets.GA_SECRET }}
run: npm run release
# https://abskmj.github.io/notes/posts/github/actions/setup-snapcraft/
# - name: Install Snapcraft
# uses: samuelmeuli/action-snapcraft@v1
# if: startsWith(matrix.os, 'ubuntu')
# with:
# snapcraft_token: ${{ secrets.SNAPCRAFT_TOKEN }}
# Mac building fails for some reason when in the same matrix as the other builds or without the other builds,
# So that's why it is here:
publish_mac:
name: "Publish MacOS"
runs-on: macos-latest
steps:
- name: Check out Git repository
uses: actions/checkout@v2
- name: Install Node.js and NPM
uses: actions/setup-node@master
with:
node-version: 18
- name: Install dependencies
run: npm install
- name: Install dmg-license
run: npm i dmg-license
- name: Build app
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CSC_LINK: ${{ secrets.CSC_LINK }}
CSC_KEY_PASSWORD: ${{ secrets.CSC_KEY_PASSWORD }}
run: npm run release