diff --git a/common/changes/@microsoft/rush/fix-variants-param_2024-09-26-22-21.json b/common/changes/@microsoft/rush/fix-variants-param_2024-09-26-22-21.json new file mode 100644 index 00000000000..6e799e637bd --- /dev/null +++ b/common/changes/@microsoft/rush/fix-variants-param_2024-09-26-22-21.json @@ -0,0 +1,10 @@ +{ + "changes": [ + { + "packageName": "@microsoft/rush", + "comment": "Fix an issue where the `--variant` parameter was missing from a phased command when the command's `alwaysInstall` property was set to `true`.", + "type": "none" + } + ], + "packageName": "@microsoft/rush" +} \ No newline at end of file diff --git a/common/config/rush/version-policies.json b/common/config/rush/version-policies.json index 3547fa4a6ce..9828f6659f1 100644 --- a/common/config/rush/version-policies.json +++ b/common/config/rush/version-policies.json @@ -103,7 +103,7 @@ "policyName": "rush", "definitionName": "lockStepVersion", "version": "5.136.0", - "nextBump": "minor", + "nextBump": "patch", "mainProject": "@microsoft/rush" } ] diff --git a/libraries/rush-lib/src/cli/scriptActions/PhasedScriptAction.ts b/libraries/rush-lib/src/cli/scriptActions/PhasedScriptAction.ts index 90a01d3e463..e37701e73a0 100644 --- a/libraries/rush-lib/src/cli/scriptActions/PhasedScriptAction.ts +++ b/libraries/rush-lib/src/cli/scriptActions/PhasedScriptAction.ts @@ -260,7 +260,9 @@ export class PhasedScriptAction extends BaseScriptAction { 'Normally a phased command expects "rush install" to have been manually run first. If this flag is specified, ' + 'Rush will automatically perform an install before processing the current command.' }); + } + if (this._alwaysInstall !== undefined) { this._variantParameter = this.defineStringParameter(VARIANT_PARAMETER); } diff --git a/libraries/rush-lib/src/logic/installManager/doBasicInstallAsync.ts b/libraries/rush-lib/src/logic/installManager/doBasicInstallAsync.ts index 8c830471f5d..05d3aa49c89 100644 --- a/libraries/rush-lib/src/logic/installManager/doBasicInstallAsync.ts +++ b/libraries/rush-lib/src/logic/installManager/doBasicInstallAsync.ts @@ -38,7 +38,7 @@ export async function doBasicInstallAsync(options: IRunInstallOptions): Promise< VersionMismatchFinder.ensureConsistentVersions(rushConfiguration, terminal, { variant, - subspace: undefined + subspace }); SetupChecks.validate(rushConfiguration);