Skip to content

Commit 4d5a7a0

Browse files
pyramationclaude
andcommitted
Add pnpm supply-chain policy (recipe A)
Third-party releases now wait 2 days before install — a compromised release is normally reported and yanked within hours, so the short wait catches it without stalling upgrades. The release-age exemption list (first-party scopes/packages) is derived from what we actually publish and resolve in this lockfile via @constructive-io/pnpm-policy's inventory, rather than hand-maintained per repo. - pnpm-policy.yaml: policy source of truth; pnpm-workspace.yaml's policy keys are generated from it and drift-checked in CI. - allowBuilds: nx (transitive dep of lerna via @nx/devkit) and unrs-resolver (transitive dep of jest-resolve) — both needed for build/versioning and test tooling respectively. - blockExoticSubdeps stays true: no git/URL-sourced transitive deps found in the lockfile. - Wired `pnpm run policy:check` into the existing acceptance workflow right after `pnpm install`. Part of the org-wide rollout tracked in constructive-io/constructive-planning#1464. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CEswUi4ANuB58rva48aHge
1 parent 456875f commit 4d5a7a0

5 files changed

Lines changed: 181 additions & 48 deletions

File tree

.github/workflows/ci.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,9 @@ jobs:
6060
- name: Install
6161
run: pnpm install
6262

63+
- name: Check supply-chain policy
64+
run: pnpm run policy:check
65+
6366
- name: Cache pgpm CLI
6467
uses: actions/cache@v4
6568
with:

package.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,21 +20,25 @@
2020
"test": "pnpm -r run test",
2121
"lint": "pnpm -r run lint",
2222
"deps": "pnpm up -r -i -L",
23-
"version": "pgpm sync-versions"
23+
"version": "pgpm sync-versions",
24+
"policy": "pnpm-policy generate",
25+
"policy:check": "pnpm-policy check"
2426
},
2527
"devDependencies": {
28+
"@constructive-io/pnpm-policy": "0.2.1",
2629
"@types/jest": "^30.0.0",
2730
"@types/node": "^25.0.3",
2831
"@typescript-eslint/eslint-plugin": "^8.50.1",
2932
"@typescript-eslint/parser": "^8.50.1",
33+
"eslint": "^9.39.2",
3034
"eslint-config-prettier": "^10.1.8",
3135
"eslint-plugin-simple-import-sort": "^12.1.1",
3236
"eslint-plugin-unused-imports": "^4.3.0",
33-
"eslint": "^9.39.2",
3437
"jest": "^30.2.0",
3538
"lerna": "^9.0.3",
3639
"makage": "^0.3.0",
3740
"pgsql-test": "^4.9.4",
41+
"pnpm-policy": "^0.2.2",
3842
"prettier": "^3.7.4",
3943
"ts-jest": "^29.4.6",
4044
"ts-node": "^10.9.2",

0 commit comments

Comments
 (0)