Skip to content

Commit a4aed48

Browse files
ci: enable npm provenance (TanStack#1941)
1 parent 89de378 commit a4aed48

File tree

4 files changed

+14
-6
lines changed

4 files changed

+14
-6
lines changed

.github/workflows/ci.yml

+6-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77
description: override release tag
88
required: false
99
push:
10-
branches: ['main', 'alpha', 'beta']
10+
branches: [main, alpha, beta]
1111

1212
concurrency:
1313
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
@@ -16,6 +16,10 @@ concurrency:
1616
env:
1717
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
1818

19+
permissions:
20+
contents: write
21+
id-token: write
22+
1923
jobs:
2024
test-and-publish:
2125
name: Test & Publish
@@ -42,6 +46,6 @@ jobs:
4246
npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}"
4347
pnpm run cipublish
4448
env:
45-
GH_TOKEN: ${{ secrets.GH_TOKEN }}
49+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4650
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
4751
TAG: ${{ inputs.tag }}

.github/workflows/pr.yml

+6-3
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ concurrency:
1010
env:
1111
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
1212

13+
permissions:
14+
contents: read
15+
1316
jobs:
1417
test:
1518
name: Test
@@ -26,8 +29,8 @@ jobs:
2629
- name: Get base and head commits for `nx affected`
2730
uses: nrwl/nx-set-shas@v4
2831
with:
29-
main-branch-name: 'main'
30-
- name: Run Tests
32+
main-branch-name: main
33+
- name: Run Checks
3134
run: pnpm run test:pr --parallel=3
3235
- name: Stop Nx Agents
3336
if: ${{ always() }}
@@ -45,7 +48,7 @@ jobs:
4548
- name: Get base and head commits for `nx affected`
4649
uses: nrwl/nx-set-shas@v4
4750
with:
48-
main-branch-name: 'main'
51+
main-branch-name: main
4952
- name: Build dependecies
5053
run: pnpm run build:all
5154
- name: Get Replay Chromium

.npmrc

+1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
link-workspace-packages=true
22
prefer-workspace-packages=true
3+
provenance=true

.nvmrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v20.15.0
1+
20.15.1

0 commit comments

Comments
 (0)