@@ -21,7 +21,6 @@ import { VersionPolicyConfiguration } from './VersionPolicyConfiguration';
2121import { EnvironmentConfiguration } from './EnvironmentConfiguration' ;
2222import { CommonVersionsConfiguration } from './CommonVersionsConfiguration' ;
2323import { Utilities } from '../utilities/Utilities' ;
24- import { Variants } from './Variants' ;
2524
2625const MINIMUM_SUPPORTED_RUSH_JSON_VERSION : string = '0.0.0' ;
2726
@@ -727,8 +726,8 @@ export class RushConfiguration {
727726 * determines which variant, if any, was last specified when performing "rush install"
728727 * or "rush update".
729728 */
730- public get currentInstalledVariant ( ) : Variants . IVariantName {
731- let variant : Variants . IVariantName ;
729+ public get currentInstalledVariant ( ) : string | undefined {
730+ let variant : string | undefined ;
732731
733732 if ( FileSystem . exists ( this . _currentVariantJsonFilename ) ) {
734733 const currentVariantJson : ICurrentVariantJson = JsonFile . load ( this . _currentVariantJsonFilename ) ;
@@ -751,7 +750,7 @@ export class RushConfiguration {
751750 * Gets the settings from the common-versions.json config file for a specific variant.
752751 * @param variant - The name of the current variant in use by the active command.
753752 */
754- public getCommonVersions ( variant ?: Variants . IVariantName ) : CommonVersionsConfiguration {
753+ public getCommonVersions ( variant ?: string | undefined ) : CommonVersionsConfiguration {
755754 const commonVersionsFilename : string = path . join ( this . commonRushConfigFolder ,
756755 ...( variant ? [ RushConstants . rushVariantsFolderName , variant ] : [ ] ) ,
757756 RushConstants . commonVersionsFilename ) ;
@@ -762,7 +761,7 @@ export class RushConfiguration {
762761 * Gets the committed shrinkwrap file name for a specific variant.
763762 * @param variant - The name of the current variant in use by the active command.
764763 */
765- public getCommittedShrinkwrapFilename ( variant ?: Variants . IVariantName ) : string {
764+ public getCommittedShrinkwrapFilename ( variant ?: string | undefined ) : string {
766765 if ( variant ) {
767766 if ( ! this . _variants [ variant ] ) {
768767 throw new Error (
@@ -795,7 +794,7 @@ export class RushConfiguration {
795794 * Gets the PNPM file name for a specific variant.
796795 * @param variant - The name of the current variant in use by the active command.
797796 */
798- public getPnpmFilename ( variant ?: Variants . IVariantName ) : string {
797+ public getPnpmFilename ( variant ?: string | undefined ) : string {
799798 const variantConfigFolderPath : string = this . _getVariantConfigFolderPath ( variant ) ;
800799
801800 return path . join (
@@ -1096,7 +1095,7 @@ export class RushConfiguration {
10961095 } ) ;
10971096 }
10981097
1099- private _getVariantConfigFolderPath ( variant ?: Variants . IVariantName ) : string {
1098+ private _getVariantConfigFolderPath ( variant ?: string | undefined ) : string {
11001099 if ( variant ) {
11011100 if ( ! this . _variants [ variant ] ) {
11021101 throw new Error (
0 commit comments