Skip to content
New issue

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

[rush-lib] fix: update shrinkwrap when globalOverrides has change #4898

Merged
merged 1 commit into from
Aug 22, 2024

Conversation

kenrick95
Copy link
Contributor

Summary

Fixes #4820

Details

Add one more condition in WorkspaceInstallManager to compare the objects:

  • pnpm-config.json's globalOverrides
  • shrinkwrap's overrides

How it was tested

  1. Run testrush update in a Rush repo
  2. Change globalOverrides
  3. Run testrush update and expect that it updates the lockfile
> testrush update

Rush Multi-Project Build Tool 5.132.0 (unmanaged) - https://rushjs.io
Node.js version is 18.20.4 (LTS)


Starting "rush update"

Checking Git policy for this repository.


Found files in the "common/git-hooks" folder.
Successfully installed these Git hook scripts: commit-msg, owners.json, post-checkout, pre-commit, pre-push

Trying to acquire lock for pnpm-8.15.8
Acquired lock for pnpm-8.15.8
Found pnpm version 8.15.8 in /path/to/user/.rush/node-v18.20.4/pnpm-8.15.8

Symlinking "/path/to/repo/common/temp/pnpm-local"
  --> "/path/to/user/.rush/node-v18.20.4/pnpm-8.15.8"
Transforming /path/to/repo/common/config/rush/.npmrc
  --> "/path/to/repo/common/temp/.npmrc"

Updating workspace files in /path/to/repo/common/temp
Copying "/path/to/repo/common/config/rush/pnpm-lock.yaml"
  --> "/path/to/repo/common/temp/pnpm-lock.yaml"
Copying "/path/to/repo/common/config/rush/pnpm-lock.yaml"
  --> "/path/to/repo/common/temp/pnpm-lock-preinstall.yaml"

The shrinkwrap file (pnpm-lock.yaml) contains the following issues:
  The overrides settings doesn't match the current shrinkwrap.


Checking installation in "/path/to/repo/common/temp"

Running "pnpm install" in /path/to/repo/common/temp

Impacted documentation

N/A

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Closed
Development

Successfully merging this pull request may close these issues.

[rush] shrinkwrapIsUpToDate does not take globalOverrides into account
2 participants