Skip to content

Commit 780b08c

Browse files
committed
Pass node_auth_token to workflows
1 parent ff377bc commit 780b08c

File tree

4 files changed

+14
-2
lines changed

4 files changed

+14
-2
lines changed

.github/workflows/_build.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ on:
99
type: string
1010
required: false
1111
default: '18'
12+
secrets:
13+
node_auth_token:
14+
description: The Node.js auth token.
15+
required: true
1216
outputs:
1317
artifact_name:
1418
description: The artifact name.
@@ -26,7 +30,7 @@ jobs:
2630
uses: ./.github/actions/setup
2731
with:
2832
node_version: ${{ inputs.node_version }}
29-
node_auth_token: ${{ secrets.GH_TOKEN }}
33+
node_auth_token: ${{ secrets.node_auth_token }}
3034
- name: Build
3135
run: npm run build
3236
- name: Package

.github/workflows/_publish.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@ on:
1212
description: The package registry host.
1313
type: string
1414
required: true
15+
node_auth_token:
16+
description: The Node.js auth token.
17+
required: true
1518
secrets:
1619
registry_token:
1720
description: The package registry token.
@@ -29,7 +32,7 @@ jobs:
2932
uses: ./.github/actions/setup
3033
with:
3134
install_dependencies: 'false'
32-
node_auth_token: ${{ secrets.GH_TOKEN }}
35+
node_auth_token: ${{ secrets.node_auth_token }}
3336
- name: Download artifact
3437
uses: actions/download-artifact@v3
3538
with:

.github/workflows/check.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ jobs:
6161
build:
6262
name: Build
6363
uses: ./.github/workflows/_build.yml
64+
secrets:
65+
node_auth_token: ${{ secrets.GH_TOKEN }}
6466
install:
6567
name: Install (Node.js v${{ matrix.node }} on ${{ matrix.os_name }})
6668
runs-on: ${{ matrix.os }}

.github/workflows/publish.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ jobs:
1212
build:
1313
name: Build
1414
uses: ./.github/workflows/_build.yml
15+
secrets:
16+
node_auth_token: ${{ secrets.GH_TOKEN }}
1517
release:
1618
name: GitHub Releases
1719
runs-on: ubuntu-latest
@@ -55,3 +57,4 @@ jobs:
5557
registry_host: https://npm.pkg.github.com
5658
secrets:
5759
registry_token: ${{ secrets.GITHUB_TOKEN }}
60+
node_auth_token: ${{ secrets.GH_TOKEN }}

0 commit comments

Comments
 (0)