-
Notifications
You must be signed in to change notification settings - Fork 16
59 lines (48 loc) · 1.23 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
name: Publish
on:
push:
tags:
- "v*"
env:
PRODUCT_NAME: "JDTreasureGrabber"
permissions:
contents: write
jobs:
release:
name: Publish release
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [windows-latest, macos-latest, ubuntu-latest]
steps:
- name: Check out git repository
uses: actions/checkout@v3
- name: Install Node.js
uses: actions/setup-node@v3
with:
node-version-file: "package.json"
- name: Install Dependencies
run: yarn
- name: Build Electron App
run: yarn dist
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: upload artifacts
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}
path: |
dist/${{ env.PRODUCT_NAME }}*.*
dist/latest*.yml
if-no-files-found: error
- name: release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
dist/${{ env.PRODUCT_NAME }}*.*
dist/latest*.yml
fail_on_unmatched_files: true
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}