Skip to content

Commit 19ec7e0

Browse files
authored
chore: bump actions and add packages tests (#4411)
1 parent 958d0e4 commit 19ec7e0

16 files changed

+107
-34
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ jobs:
2020

2121
steps:
2222
- name: Checkout Z-Wave JS UI
23-
uses: actions/checkout@v4
23+
uses: actions/checkout@v5
2424

2525
- name: Use Node.js ${{ matrix.node-version }}
26-
uses: actions/setup-node@v4
26+
uses: actions/setup-node@v5
2727
with:
2828
node-version: ${{ matrix.node-version }}
2929
cache: 'npm'

.github/workflows/codeql-analysis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
language: ['javascript']
2020
steps:
2121
- name: Checkout repository
22-
uses: actions/checkout@v4
22+
uses: actions/checkout@v5
2323

2424
- name: Initialize CodeQL
2525
uses: github/codeql-action/init@v2

.github/workflows/discord-publish.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ jobs:
1111

1212
steps:
1313
- name: Check out code
14-
uses: actions/checkout@v4
14+
uses: actions/checkout@v5
1515

16-
- uses: actions/github-script@v6
16+
- uses: actions/github-script@v8
1717
name: Post release notes to Discord
1818
env:
1919
DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}

.github/workflows/docker-release-test.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,12 @@ jobs:
1717
packages: write
1818
runs-on: ubuntu-latest
1919
steps:
20-
- uses: actions/checkout@v4
20+
- uses: actions/checkout@v5
2121
with:
2222
fetch-depth: 0 # fetch everything
2323
ref: ${{ github.event.inputs.branch }}
2424

25-
- uses: actions/setup-node@v4
25+
- uses: actions/setup-node@v5
2626
with:
2727
node-version: 20
2828
cache: 'npm'
@@ -65,7 +65,7 @@ jobs:
6565
npm run build
6666
6767
- name: build+push
68-
uses: docker/build-push-action@v5
68+
uses: docker/build-push-action@v6
6969
timeout-minutes: 120
7070
with:
7171
platforms: linux/arm64,linux/amd64,linux/arm/v6,linux/arm/v7

.github/workflows/docker-release.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ jobs:
1919
runs-on: ubuntu-latest
2020
steps:
2121
- uses: catchpoint/workflow-telemetry-action@v1
22-
- uses: actions/checkout@v4
23-
- uses: actions/setup-node@v4
22+
- uses: actions/checkout@v5
23+
- uses: actions/setup-node@v5
2424
with:
2525
node-version: 20
2626
cache: 'npm'
@@ -82,7 +82,7 @@ jobs:
8282
8383
- name: build+push
8484
timeout-minutes: 120 # prevents this to run indeterminatly
85-
uses: docker/build-push-action@v5
85+
uses: docker/build-push-action@v6
8686
with:
8787
platforms: linux/arm64,linux/amd64,linux/arm/v6,linux/arm/v7
8888
file: docker/Dockerfile
@@ -95,7 +95,7 @@ jobs:
9595

9696
- name: build+push zwavejs2mqtt
9797
timeout-minutes: 120
98-
uses: docker/build-push-action@v5
98+
uses: docker/build-push-action@v6
9999
with:
100100
platforms: linux/arm64,linux/amd64,linux/arm/v6,linux/arm/v7
101101
file: docker/Dockerfile

.github/workflows/docker-test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
matrix:
1717
platforms: [linux/amd64, linux/arm64, linux/arm/v7]
1818
steps:
19-
- uses: actions/checkout@v4
19+
- uses: actions/checkout@v5
2020

2121
- uses: docker/setup-buildx-action@v3
2222
- uses: docker/setup-qemu-action@v3
@@ -45,7 +45,7 @@ jobs:
4545
maintainer=robertsLando
4646
4747
- name: Buildx build
48-
uses: docker/build-push-action@v5
48+
uses: docker/build-push-action@v6
4949
timeout-minutes: 120
5050
with:
5151
platforms: ${{ matrix.platform }}

.github/workflows/package_arm64.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ jobs:
1414
matrix:
1515
node-version: [20.x]
1616
steps:
17-
- uses: actions/checkout@v4
17+
- uses: actions/checkout@v5
1818

1919
- name: Use Node.js ${{ matrix.node-version }}
20-
uses: actions/setup-node@v4
20+
uses: actions/setup-node@v5
2121
with:
2222
node-version: ${{ matrix.node-version }}
2323
cache: "npm"

.github/workflows/package_armv7.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ jobs:
1414
matrix:
1515
node-version: [20.x] # NB: when pkg-fetch bumps binaries, this must be updated
1616
steps:
17-
- uses: actions/checkout@v4
17+
- uses: actions/checkout@v5
1818

1919
- name: Setup Node.js
20-
uses: actions/setup-node@v4
20+
uses: actions/setup-node@v5
2121
with:
2222
node-version: ${{ matrix.node-version }}
2323
cache: "npm"

.github/workflows/package_x64.yml

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
name: Build pkg x64
2+
3+
on:
4+
release:
5+
types:
6+
- created
7+
workflow_dispatch:
8+
push:
9+
branches:
10+
- master
11+
pull_request:
12+
13+
jobs:
14+
build:
15+
name: Build package and attach to release
16+
runs-on: ubuntu-latest
17+
strategy:
18+
matrix:
19+
node-version: [20.x]
20+
steps:
21+
- uses: actions/checkout@v5
22+
23+
- name: Use Node.js ${{ matrix.node-version }}
24+
uses: actions/setup-node@v5
25+
with:
26+
node-version: ${{ matrix.node-version }}
27+
cache: "npm"
28+
29+
- name: Install and pre-build
30+
run: |
31+
npm ci
32+
npm run build
33+
34+
- name: Build for x64
35+
run: |
36+
npm run pkg -- --bundle --skip-build
37+
38+
- name: Test built package
39+
run: |
40+
41+
echo "Testing application startup..."
42+
timeout 10s ./build/pkg/zwave-js-ui-linux &
43+
app_pid=$!
44+
45+
# Wait a few seconds for the app to start
46+
sleep 5
47+
48+
# Check if process is still running (indicates successful startup)
49+
if kill -0 $app_pid 2>/dev/null; then
50+
echo "Package test passed: Application started successfully"
51+
# Kill the application
52+
kill $app_pid 2>/dev/null || true
53+
wait $app_pid 2>/dev/null || true
54+
else
55+
echo "Package test failed: Application failed to start or crashed immediately"
56+
exit 1
57+
fi
58+
59+
- name: Upload artifacts
60+
if: github.event_name == 'workflow_dispatch'
61+
uses: actions/upload-artifact@v4
62+
with:
63+
name: pkg-build
64+
path: ./build/pkg/*.zip
65+
66+
- name: Upload binaries to release
67+
if: github.event_name == 'release'
68+
uses: svenstaro/upload-release-action@v2
69+
with:
70+
repo_token: ${{ secrets.GITHUB_TOKEN }}
71+
file: ./build/pkg/*.zip
72+
file_glob: true
73+
tag: ${{ github.ref }}
74+
overwrite: true

.github/workflows/release-it.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@ jobs:
1919
node-version: [20.x]
2020
steps:
2121
- name: Checkout master
22-
uses: actions/checkout@v4
22+
uses: actions/checkout@v5
2323
with:
2424
ref: 'master'
2525
fetch-depth: 0 # fetch all commits history to create the changelog
2626
token: ${{ secrets.BOT_TOKEN }}
2727

2828
- name: Use Node.js ${{ matrix.node-version }}
29-
uses: actions/setup-node@v4
29+
uses: actions/setup-node@v5
3030
with:
3131
node-version: ${{ matrix.node-version }}
3232
cache: 'npm'

0 commit comments

Comments
 (0)