Skip to content

Commit

Permalink
ci: enable npm provenance (#7716)
Browse files Browse the repository at this point in the history
* ci: enable npm provenance

* Update @tanstack/config
  • Loading branch information
lachlancollins authored Jul 11, 2024
1 parent b58da75 commit c6d68d8
Show file tree
Hide file tree
Showing 6 changed files with 114 additions and 204 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
description: override release tag
required: false
push:
branches: ['main', 'alpha', 'beta', 'rc', 'v4']
branches: [main, alpha, beta, rc, v4]

concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
Expand All @@ -16,6 +16,10 @@ concurrency:
env:
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}

permissions:
contents: write
id-token: write

jobs:
test-and-publish:
name: Test & Publish
Expand All @@ -42,7 +46,7 @@ jobs:
npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}"
pnpm run cipublish
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
TAG: ${{ inputs.tag }}
- name: Upload coverage to Codecov
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ concurrency:
env:
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}

permissions:
contents: read

jobs:
test:
name: Test
Expand All @@ -28,8 +31,8 @@ jobs:
- name: Get base and head commits for `nx affected`
uses: nrwl/nx-set-shas@v4
with:
main-branch-name: 'main'
- name: Run Tests
main-branch-name: main
- name: Run Checks
run: pnpm run test:pr --parallel=3
- name: Stop Nx Agents
if: ${{ always() }}
Expand Down
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
link-workspace-packages=true
prefer-workspace-packages=true
provenance=true
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v22.2.0
22.4.0
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
"@cspell/eslint-plugin": "^8.9.1",
"@eslint-react/eslint-plugin": "^1.5.16",
"@solidjs/testing-library": "^0.8.8",
"@tanstack/config": "^0.9.0",
"@tanstack/config": "^0.9.6",
"@testing-library/jest-dom": "^6.4.5",
"@testing-library/react": "^15.0.7",
"@types/node": "^20.12.12",
Expand Down
Loading

0 comments on commit c6d68d8

Please sign in to comment.