-
Notifications
You must be signed in to change notification settings - Fork 48
79 lines (60 loc) · 1.79 KB
/
build.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
76
77
78
name: build-release
on:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: apt update
run: sudo apt-get update
- name: Install apt packages
run: sudo apt-get install libavahi-compat-libdnssd-dev jq libudev-dev
- name: Setup Node.js for use with actions
uses: actions/setup-node@v2-beta
with:
node-version: '14'
- uses: actions/checkout@v2
- name: Cache node modules
uses: actions/cache@v1
env:
cache-name: cache-node-modules
with:
path: ~/.npm # npm cache files are stored in `~/.npm` on Linux/macOS
key: ${{ runner.os }}-build-${{ env.cache-name }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
# - uses: EndBug/[email protected]
# name: Check for version change
# id: check_version
# with:
# diff-search: true
- name: get-npm-version
id: package-version
uses: martinbeentjes/npm-get-version-action@master
- uses: rickstaa/action-create-tag@v1
with:
tag: "v${{ steps.package-version.outputs.current-version}}"
- name: Build addon package
run: ./build.sh
# - uses: actions/upload-artifact@v1
# name: Save release artifacts
# with:
# name: release
# path: dist
# - uses: actions/upload-artifact@v1
# name: Save changelog
# with:
# name: description
# path: RELEASE_BODY.md
- uses: ncipollo/release-action@v1
name: Create Release
with:
draft: true
prerelease: true
artifacts: dist/*
bodyFile: RELEASE_BODY.md
tag: "v${{ steps.package-version.outputs.current-version}}"