Skip to content

Commit 9ca56cd

Browse files
committed
feat(ci): switch to canonical fleet pnpm CI workflow
The hand-rolled `test.yml` ran `npm i` against a package.json that declares `@socketsecurity/lib` via the `catalog:` protocol. npm doesn't understand `catalog:` (it's pnpm-specific syntax) and crashed with EUNSUPPORTEDPROTOCOL on every CI run. Three changes: 1. Add `.github/workflows/ci.yml` — the canonical fleet CI workflow that delegates to `SocketDev/socket-registry/.github/workflows/ci.yml@<sha>`. That reusable workflow sets up pnpm + node correctly and runs the fleet's standard lint/type/test pipeline. This is the same file every fleet repo carries (managed by wheelhouse sync-scaffolding's IDENTICAL_FILES). 2. Delete `.github/workflows/test.yml` — the hand-rolled workflow that pre-dated the fleet pnpm policy. Its job ("run `pnpm test` on push/PR") is now done by the canonical CI workflow. 3. Migrate `.github/workflows/provenance.yml` from `npm install -g npm@latest && npm ci` to `pnpm install --frozen-lockfile`. Keep `npm publish --provenance` at the end — that's still the canonical sigstore-attested publisher (pnpm publish forwards to it anyway). After this, `oxlint --config .config/oxlintrc.json` is clean and the wheelhouse `socket/workflow_npm_install` check (committed alongside in socket-wheelhouse@3ff8e5e) reports 0 findings on this repo.
1 parent 4a7f7c3 commit 9ca56cd

3 files changed

Lines changed: 35 additions & 37 deletions

File tree

.github/workflows/ci.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: ⚡ CI
2+
3+
# Dependencies:
4+
# - SocketDev/socket-registry/.github/workflows/ci.yml
5+
6+
on:
7+
push:
8+
branches: [main]
9+
tags: ['*']
10+
pull_request:
11+
branches: [main]
12+
workflow_dispatch:
13+
14+
permissions:
15+
contents: read
16+
17+
concurrency:
18+
group: ${{ github.workflow }}-${{ github.ref }}
19+
cancel-in-progress: true
20+
21+
jobs:
22+
ci:
23+
name: Run CI Pipeline
24+
uses: SocketDev/socket-registry/.github/workflows/ci.yml@ba3d42dec13db8da746d695aac12f0d7d47f8719 # main

.github/workflows/provenance.yml

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,20 +25,26 @@ jobs:
2525
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 (2026-05-15)
2626
with:
2727
persist-credentials: false
28+
- name: Install pnpm
29+
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0 (2026-05-18)
30+
with:
31+
run_install: false
2832
- uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 (2026-05-15)
2933
with:
3034
node-version: '22'
3135
registry-url: 'https://registry.npmjs.org'
3236
scope: '@socketregistry'
33-
package-manager-cache: false
34-
- run: npm install -g npm@latest
35-
- run: npm ci
37+
cache: pnpm
38+
- run: pnpm install --frozen-lockfile
3639
- name: Build package
37-
run: npm run build
40+
run: pnpm run build
3841
- name: Get package version
3942
id: package-version
4043
run: echo "version=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT
41-
- run: npm pack
44+
- run: pnpm pack
45+
# `pnpm publish --provenance` forwards to `npm publish --provenance`
46+
# for sigstore attestation; keep `npm publish` here for explicitness
47+
# so the provenance path is obvious in the workflow.
4248
- run: npm publish --provenance --access public
4349
env:
4450
SOCKET_CLI_DEBUG: ${{ inputs.debug }}

.github/workflows/test.yml

Lines changed: 0 additions & 32 deletions
This file was deleted.

0 commit comments

Comments
 (0)