Skip to content

Commit cdb7839

Browse files
panvamarco-ippolito
authored andcommitted
tools: run daily WPT.fyi report on all supported releases
PR-URL: #55619 Reviewed-By: Richard Lau <rlau@redhat.com> Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
1 parent 1bb461e commit cdb7839

File tree

1 file changed

+13
-7
lines changed

1 file changed

+13
-7
lines changed

.github/workflows/daily-wpt-fyi.yml

+13-7
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,6 @@ name: Daily WPT report
66

77
on:
88
workflow_dispatch:
9-
inputs:
10-
node-versions:
11-
description: Node.js versions (as supported by actions/setup-node) to test as JSON array
12-
required: false
13-
default: '["current", "lts/*", "lts/-1"]'
149
schedule:
1510
# This is 20 minutes after `epochs/daily` branch is triggered to be created
1611
# in WPT repo.
@@ -24,11 +19,22 @@ permissions:
2419
contents: read
2520

2621
jobs:
27-
report:
22+
collect-versions:
2823
if: github.repository == 'nodejs/node' || github.event_name == 'workflow_dispatch'
24+
runs-on: ubuntu-latest
25+
outputs:
26+
matrix: ${{ steps.query.outputs.matrix }}
27+
steps:
28+
- id: query
29+
run: |
30+
matrix=$(curl -s https://raw.githubusercontent.com/nodejs/Release/refs/heads/main/schedule.json | jq --arg now "$(date +%Y-%m-%d)" '[with_entries(select(.value.end > $now and .value.start < $now)) | keys[] | ltrimstr("v") | tonumber] + ["latest-nightly"]')
31+
echo "matrix=$matrix" >> "$GITHUB_OUTPUT"
32+
report:
33+
needs:
34+
- collect-versions
2935
strategy:
3036
matrix:
31-
node-version: ${{ fromJSON(github.event.inputs.node-versions || '["latest-nightly", "current", "lts/*", "lts/-1"]') }}
37+
node-version: ${{ fromJSON(needs.collect-versions.outputs.matrix) }}
3238
fail-fast: false
3339
runs-on: ubuntu-latest
3440
steps:

0 commit comments

Comments
 (0)