Skip to content

chore: invoke local bins directly instead of via npx#1009

Merged
antfu merged 1 commit into
nuxt:mainfrom
antfubot:chore/run-local-bins-directly
Jun 15, 2026
Merged

chore: invoke local bins directly instead of via npx#1009
antfu merged 1 commit into
nuxt:mainfrom
antfubot:chore/run-local-bins-directly

Conversation

@antfubot

Copy link
Copy Markdown
Contributor

These binaries (discovery-build, simple-git-hooks, lint-staged) are already installed as local devDependencies, so the package manager puts them on PATH for scripts. Calling them directly instead of through npx avoids an unnecessary resolution step and keeps the scripts consistent (e.g. dev:discovery already calls its bin directly).

This PR was created with the help of an agent.

@antfu antfu merged commit e491e9a into nuxt:main Jun 15, 2026
4 of 7 checks passed
@coderabbitai

coderabbitai Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Walkthrough

Three npm script entries across two package.json files are updated to remove the npx prefix from tool invocations. In the root package.json, the postinstall script now calls simple-git-hooks directly, and the simple-git-hooks.pre-commit hook now calls lint-staged directly. In packages/devtools/package.json, the build:discovery script now calls discovery-build directly. All other arguments and chained commands remain unchanged.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately and concisely summarizes the main change: replacing npx invocations with direct binary calls in package scripts.
Description check ✅ Passed The description clearly explains the rationale and context for the changes, including why direct invocations are preferable and noting consistency improvements.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants