-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (57 loc) · 1.56 KB
/
build.yaml
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
name: Build
on: push
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: .nvmrc
cache: npm
- run: npm install --prefer-offline --no-audit
- run: npx eslint .
- run: npx prettier --check .
build:
name: Build
runs-on: macos-latest
needs: lint
steps:
- uses: actions/checkout@v4
with:
submodules: true
- if: startsWith(github.ref, 'refs/tags/')
run: |
export VERSION="${GITHUB_REF_NAME#v}"
yq --inplace '.Version = strenv(VERSION)' src/*/manifest.json
- uses: AdamCarballo/streamdeck-distribution-tool@v1.0.2
with:
input: src/com.gabe565.nightscout.sdPlugin
- uses: actions/upload-artifact@v4
with:
name: release
path: com.gabe565.nightscout.streamDeckPlugin
release:
name: Release
runs-on: ubuntu-latest
needs: build
if: startsWith(github.ref, 'refs/tags/')
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: true
- uses: actions/download-artifact@v4
with:
name: release
- name: Generate Changelog
id: changelog
uses: gabe565/changelog-generator@v1
- name: Release
uses: softprops/action-gh-release@v2
with:
body: ${{ steps.changelog.outputs.changelog }}
files: com.gabe565.nightscout.streamDeckPlugin