зеркало из https://github.com/microsoft/rushstack.git
fix: update shrinkwrap when globalOverrides has change (#4898)
This commit is contained in:
Родитель
4cd9b54ad7
Коммит
de9aa4aef0
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
"changes": [
|
||||
{
|
||||
"packageName": "@microsoft/rush",
|
||||
"comment": "Always update shrinkwrap when globalOverrides has been changed",
|
||||
"type": "none"
|
||||
}
|
||||
],
|
||||
"packageName": "@microsoft/rush"
|
||||
}
|
|
@ -367,6 +367,17 @@ export class WorkspaceInstallManager extends BaseInstallManager {
|
|||
shrinkwrapIsUpToDate = false;
|
||||
}
|
||||
|
||||
// Check if overrides and globalOverrides are the same
|
||||
const overridesAreEqual: boolean = objectsAreDeepEqual<Record<string, string>>(
|
||||
this.rushConfiguration.pnpmOptions.globalOverrides ?? {},
|
||||
shrinkwrapFile?.overrides ? Object.fromEntries(shrinkwrapFile?.overrides) : {}
|
||||
);
|
||||
|
||||
if (!overridesAreEqual) {
|
||||
shrinkwrapWarnings.push("The overrides settings doesn't match the current shrinkwrap.");
|
||||
shrinkwrapIsUpToDate = false;
|
||||
}
|
||||
|
||||
// Write the common package.json
|
||||
InstallHelpers.generateCommonPackageJson(this.rushConfiguration, subspace, undefined);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче