We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
With rush v5.102.0 and pnpm v8.6.12, using the --to or -t flag with rush install seems to have no effect.
--to
-t
rush install
Dependencies for all projects are still installed.
rush purge
rush install -t @myscope/myproject
@myscope/myproject
Expected result: only @myscope/myproject and its rush project dependencies have a complete node_modules folder
node_modules
Actual result: all rush projects have a complete node_modules folder
I found the (very old) issue #1669 and thought that perhaps this feature wasn't implemented.
However, I ran rush --debug install -t [my packge] and saw output that indicated rush is passing a --filter option to pnpm.
rush --debug install -t [my packge]
--filter
So, I think this is intended to work?
Specifically, this is the pnpm install command that prints out when I add --debug
--debug
$ rush --debug install -t @myscope/myproject ... Invoking package manager: /Users/jbrandt/.rush/node-v18.16.0/pnpm-8.6.12/node_modules/pnpm/bin/pnpm.cjs install --store /Users/jbrandt/.pnpmcache --config.cacheDir=/Users/jbrandt/.pnpmcache --config.stateDir=/Users/jbrandt/.pnpmcache --no-prefer-frozen-lockfile --strict-peer-dependencies --config.ignoreCompatibilityDb --recursive --link-workspace-packages false --filter @myscope/myproject...
The main reason I want this feature to work is to speed up dependency installation in our CI/CD build steps that only build a portion of our monorepo.
Thank you for all the great work you do on rush! It is a delight to use!
Please answer these questions to help us investigate your issue more quickly:
@microsoft/rush
rushVersion
pnpmVersion
useWorkspaces
node -v
The text was updated successfully, but these errors were encountered:
This is a bug in pnpm@8. Our command to pnpm is correctly formatted and results in, e.g:
/workspaces/rushstack/common/temp (pnpm-latest) $ rush install --to @rushstack/heft Running "pnpm install" in /workspaces/rushstack/common/temp Scope: 14 of 130 workspace projects
However, pnpm itself then installs the dependencies in all projects.
See pnpm/pnpm#6300
Edit: looks like we may be able to work around this by passing --config.dedupe-peer-dependents=false when installing with --frozen-lockfile.
--config.dedupe-peer-dependents=false
--frozen-lockfile
Sorry, something went wrong.
dmichon-msft
Successfully merging a pull request may close this issue.
Summary
With rush v5.102.0 and pnpm v8.6.12, using the
--to
or-t
flag withrush install
seems to have no effect.Dependencies for all projects are still installed.
Repro steps
rush purge
rush install -t @myscope/myproject
where@myscope/myproject
is a workspace projectExpected result: only
@myscope/myproject
and its rush project dependencies have a completenode_modules
folderActual result: all rush projects have a complete
node_modules
folderDetails
I found the (very old) issue #1669 and thought that perhaps this feature wasn't implemented.
However, I ran
rush --debug install -t [my packge]
and saw output that indicated rush is passing a--filter
option to pnpm.So, I think this is intended to work?
Specifically, this is the pnpm install command that prints out when I add
--debug
The main reason I want this feature to work is to speed up dependency installation in our CI/CD build steps that only build a portion of our monorepo.
Thank you for all the great work you do on rush! It is a delight to use!
Standard questions
Please answer these questions to help us investigate your issue more quickly:
@microsoft/rush
globally installed version?rushVersion
from rush.json?pnpmVersion
from rush.json?useWorkspaces
from rush.json?node -v
)?The text was updated successfully, but these errors were encountered: