Skip to content

fix(rewrite): preserve npm workspace run semantics#2576

Open
YOMXXX wants to merge 1 commit into
rtk-ai:developfrom
YOMXXX:fix/issue-2098-npm-workspace-rewrite
Open

fix(rewrite): preserve npm workspace run semantics#2576
YOMXXX wants to merge 1 commit into
rtk-ai:developfrom
YOMXXX:fix/issue-2098-npm-workspace-rewrite

Conversation

@YOMXXX

@YOMXXX YOMXXX commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Summary

  • route npm run / npm run-script commands with workspace selectors through rtk npm instead of collapsing them to tool-specific wrappers
  • detect -w, -w=, --workspace, --workspace=, --workspaces, and -ws before the npm -- script-args boundary
  • keep ordinary specialized rewrites, including npm run tsc --noEmit and script args after --

Fixes #2098.

Tests

  • cargo +1.93.0 fmt --check
  • git diff --check
  • cargo +1.93.0 test registry -- --nocapture (295 passed)
  • CLI smokes for workspace and non-workspace npm rewrites
  • cargo +1.93.0 clippy --all-targets
  • cargo +1.93.0 test --all -- --skip small_grep_not_worse_than_plain (2236 passed, 8 ignored; grep integration 12 + 4 passed)

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.

Hook rewrites npm run <script> -w <workspace>, breaking npm's --workspace flag

1 participant