Skip to content

Commit 45f92eb

Browse files
justin808claude
andcommitted
Fix package.json scripts for pnpm compatibility
pnpm uses scripts differently than yarn - when a script calls a binary from node_modules/.bin, it needs to just reference the binary name directly. Added missing scripts that master has: - nps, knip, eslint, attw, publint Also simplified lint command to just use 'nps eslint' directly. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 1464424 commit 45f92eb

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

.github/workflows/lint-js-and-ruby.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ jobs:
168168
pnpm exec knip --production --exclude binaries
169169
170170
- name: Lint JS
171-
run: pnpm run nps eslint -- --report-unused-disable-directives
171+
run: pnpm run eslint --report-unused-disable-directives
172172
- name: Check formatting
173173
run: pnpm start format.listDifferent
174174
- name: Lint SCSS with stylelint

package.json

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,17 +69,21 @@
6969
"scripts": {
7070
"test": "pnpm -r run test",
7171
"clean": "pnpm -r run clean",
72-
"start": "pnpm run nps",
72+
"start": "nps",
73+
"nps": "nps",
7374
"build": "pnpm --filter react-on-rails run build && pnpm --filter react-on-rails-pro run build && pnpm --filter react-on-rails-pro-node-renderer run build",
7475
"build-watch": "pnpm -r run build-watch",
75-
"lint": "pnpm run nps eslint",
76+
"lint": "nps eslint",
7677
"lint:scss": "stylelint \"spec/dummy/app/assets/stylesheets/**/*.scss\" \"spec/dummy/client/**/*.scss\"",
7778
"check": "pnpm run lint && pnpm -r run check",
7879
"type-check": "pnpm -r run type-check",
7980
"yalc:publish": "pnpm -r run yalc:publish",
8081
"yalc": "pnpm -r run yalc",
8182
"publish": "pnpm -r run publish",
82-
83+
"knip": "knip",
84+
"eslint": "eslint",
85+
"attw": "attw",
86+
"publint": "publint",
8387
"postinstall": "test -f .lefthook.yml && test -d .git && command -v bundle >/dev/null 2>&1 && bundle exec lefthook install || true"
8488
},
8589
"repository": {

0 commit comments

Comments
 (0)