Skip to content

Commit 182e6b9

Browse files
Mesteerybengl
authored andcommitted
build: improve consistency between workflows
PR-URL: #41791 Reviewed-By: Mary Marchini <[email protected]> Reviewed-By: Michaël Zasso <[email protected]> Reviewed-By: Tobias Nießen <[email protected]> Reviewed-By: Antoine du Hamel <[email protected]>
1 parent 3243701 commit 182e6b9

17 files changed

+35
-44
lines changed

.github/workflows/authors.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "authors update"
1+
name: Authors update
22
on:
33
schedule:
44
# Run once a week at 00:05 AM UTC on Sunday.

.github/workflows/auto-start-ci.yml

+6-6
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ env:
1212
NODE_VERSION: lts/*
1313

1414
jobs:
15-
get_prs_for_ci:
15+
get-prs-for-ci:
1616
if: github.repository == 'nodejs/node'
1717
runs-on: ubuntu-latest
1818
outputs:
@@ -29,20 +29,20 @@ jobs:
2929
--limit 100
3030
env:
3131
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
32-
startCI:
33-
needs: get_prs_for_ci
34-
if: needs.get_prs_for_ci.outputs.numbers != ''
32+
start-ci:
33+
needs: get-prs-for-ci
34+
if: needs.get-prs-for-ci.outputs.numbers != ''
3535
runs-on: ubuntu-latest
3636
steps:
3737
- uses: actions/checkout@v2
3838
with:
3939
persist-credentials: false
4040

41-
# Install dependencies
4241
- name: Install Node.js
4342
uses: actions/setup-node@v2
4443
with:
4544
node-version: ${{ env.NODE_VERSION }}
45+
4646
- name: Install node-core-utils
4747
run: npm install -g node-core-utils
4848

@@ -55,6 +55,6 @@ jobs:
5555
ncu-config set repo "$(echo ${{ github.repository }} | cut -d/ -f2)"
5656
5757
- name: Start the CI
58-
run: ./tools/actions/start-ci.sh ${{ needs.get_prs_for_ci.outputs.numbers }}
58+
run: ./tools/actions/start-ci.sh ${{ needs.get-prs-for-ci.outputs.numbers }}
5959
env:
6060
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/build-tarball.yml

+1-4
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,12 @@ on:
2525
- '!.github/workflows/build-tarball.yml'
2626

2727
env:
28+
PYTHON_VERSION: '3.10'
2829
FLAKY_TESTS: dontcare
2930

3031
jobs:
3132
build-tarball:
3233
if: github.event.pull_request.draft == false
33-
env:
34-
PYTHON_VERSION: '3.10'
3534
runs-on: ubuntu-latest
3635
steps:
3736
- uses: actions/checkout@v2
@@ -57,8 +56,6 @@ jobs:
5756
name: tarballs
5857
path: tarballs
5958
test-tarball-linux:
60-
env:
61-
PYTHON_VERSION: '3.10'
6259
needs: build-tarball
6360
runs-on: ubuntu-latest
6461
steps:

.github/workflows/build-windows.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
name: build-windows
1+
name: Build Windows
22

33
on:
44
pull_request:
55
paths-ignore:
6-
- "README.md"
6+
- README.md
77
- .github/**
88
- '!.github/workflows/build-windows.yml'
99
types: [opened, synchronize, reopened, ready_for_review]
@@ -15,7 +15,7 @@ on:
1515
- v[0-9]+.x-staging
1616
- v[0-9]+.x
1717
paths-ignore:
18-
- "README.md"
18+
- README.md
1919
- .github/**
2020
- '!.github/workflows/build-windows.yml'
2121

.github/workflows/comment-labeled.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Comment on issues and PRs when labelled
1+
name: Comment on issues and PRs when labeled
22
on:
33
issues:
44
types: [labeled]
@@ -12,7 +12,7 @@ env:
1212
FAST_TRACK_MESSAGE: Fast-track has been requested by @${{ github.actor }}. Please 👍 to approve.
1313

1414
jobs:
15-
staleComment:
15+
stale-comment:
1616
if: github.repository == 'nodejs/node' && github.event.label.name == 'stalled'
1717
runs-on: ubuntu-latest
1818
steps:
@@ -22,8 +22,8 @@ jobs:
2222
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2323
run: gh issue comment "$NUMBER" --repo ${{ github.repository }} --body "$STALE_MESSAGE"
2424

25-
fastTrack:
26-
if: github.repository == 'nodejs/node' && github.event_name == 'pull_request_target' && github.event.label.name == 'fast-track'
25+
fast-track:
26+
if: github.repository == 'nodejs/node' && github.event.issue.pull_request && github.event.label.name == 'fast-track'
2727
runs-on: ubuntu-latest
2828
steps:
2929
- name: Request Fast-Track

.github/workflows/commit-lint.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "First commit message adheres to guidelines at https://goo.gl/p2fr5Q"
1+
name: First commit message adheres to guidelines at https://goo.gl/p2fr5Q
22

33
on: [pull_request]
44

.github/workflows/coverage-linux.yml

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: coverage-linux
1+
name: Coverage Linux
22

33
on:
44
pull_request:
@@ -11,9 +11,7 @@ on:
1111
- .github/**
1212
- '!.github/workflows/coverage-linux.yml'
1313
push:
14-
branches:
15-
- master
16-
- main
14+
branches: [master, main]
1715
paths-ignore:
1816
- '**.md'
1917
- 'benchmark/**'

.github/workflows/coverage-windows.yml

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: coverage-windows
1+
name: Coverage Windows
22

33
on:
44
pull_request:
@@ -12,9 +12,7 @@ on:
1212
- .github/**
1313
- '!.github/workflows/coverage-windows.yml'
1414
push:
15-
branches:
16-
- master
17-
- main
15+
branches: [master, main]
1816
paths-ignore:
1917
- '**.md'
2018
- 'benchmark/**'

.github/workflows/misc.yml .github/workflows/doc.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: misc
1+
name: Test and upload documentation to artifacts
22

33
on:
44
pull_request:

.github/workflows/license-builder.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: license update
1+
name: License update
22
on:
33
schedule:
44
# 00:00:00 every Monday

.github/workflows/linters.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: linters
1+
name: Linters
22

33
on:
44
pull_request:
@@ -121,7 +121,7 @@ jobs:
121121
122122
lint-sh:
123123
if: github.event.pull_request.draft == false
124-
runs-on: ubuntu-20.04
124+
runs-on: ubuntu-latest
125125
steps:
126126
- uses: actions/checkout@v2
127127
with:

.github/workflows/notify-force-push.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ name: Notify on Force Push
88
jobs:
99
slackNotification:
1010
name: Slack Notification
11-
if: ${{ github.event.forced && github.repository == 'nodejs/node' }}
11+
if: github.repository == 'nodejs/node' && github.event.forced
1212
runs-on: ubuntu-latest
1313
steps:
1414
- name: Slack Notification

.github/workflows/test-asan.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: test-asan
1+
name: Test ASan
22

33
on:
44
pull_request:

.github/workflows/test-internet.yml

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: test-internet
1+
name: Test internet
22

33
on:
44
workflow_dispatch:
@@ -7,17 +7,15 @@ on:
77

88
pull_request:
99
types: [opened, synchronize, reopened, ready_for_review]
10-
paths:
11-
- test/internet/**
10+
paths: [test/internet/**]
1211
push:
1312
branches:
1413
- master
1514
- main
1615
- canary
1716
- v[0-9]+.x-staging
1817
- v[0-9]+.x
19-
paths:
20-
- test/internet/**
18+
paths: [test/internet/**]
2119

2220
env:
2321
PYTHON_VERSION: '3.10'

.github/workflows/test-linux.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
name: test-linux
1+
name: Test Linux
22

33
on:
44
pull_request:
55
paths-ignore:
6-
- "README.md"
6+
- README.md
77
- .github/**
88
- '!.github/workflows/test-linux.yml'
99
types: [opened, synchronize, reopened, ready_for_review]
@@ -15,7 +15,7 @@ on:
1515
- v[0-9]+.x-staging
1616
- v[0-9]+.x
1717
paths-ignore:
18-
- "README.md"
18+
- README.md
1919
- .github/**
2020
- '!.github/workflows/test-linux.yml'
2121

.github/workflows/test-macos.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: test-macOS
1+
name: Test macOS
22

33
on:
44
pull_request:

.github/workflows/tools.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "tools update"
1+
name: Tools update
22
on:
33
schedule:
44
# Run once a week at 00:05 AM UTC on Saturday.
@@ -7,7 +7,7 @@ on:
77
workflow_dispatch:
88

99
jobs:
10-
tools_update:
10+
tools-update:
1111
if: github.repository == 'nodejs/node'
1212
runs-on: ubuntu-latest
1313
strategy:

0 commit comments

Comments
 (0)