@rushstack/rush-sdk 5.106.0 → 5.107.1-pr3481.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/rush-lib.d.ts +177 -32
- package/dist/tsdoc-metadata.json +1 -1
- package/lib/api/CustomTipsConfiguration.d.ts +5 -9
- package/lib/api/ExperimentsConfiguration.d.ts +5 -0
- package/lib/api/LastInstallFlag.d.ts +58 -21
- package/lib/api/LastLinkFlag.d.ts +3 -7
- package/lib/api/RushConfiguration.d.ts +52 -0
- package/lib/api/RushConfigurationProject.d.ts +6 -0
- package/lib/api/base/BaseFlag.d.ts +50 -0
- package/lib/api/base/BaseFlag.js +1 -0
- package/lib/api/packageManager/PnpmPackageManager.d.ts +14 -0
- package/lib/cli/actions/InstallAction.d.ts +7 -0
- package/lib/cli/actions/ListAction.d.ts +4 -0
- package/lib/cli/actions/UpdateAction.d.ts +7 -0
- package/lib/cli/parsing/SelectionParameterSet.d.ts +17 -3
- package/lib/cli/scriptActions/PhasedScriptAction.d.ts +1 -0
- package/lib/index.d.ts +2 -1
- package/lib/logic/PurgeManager.d.ts +1 -0
- package/lib/logic/RushConstants.d.ts +6 -0
- package/lib/logic/UnlinkManager.d.ts +2 -2
- package/lib/logic/base/BaseInstallManagerTypes.d.ts +23 -0
- package/lib/logic/installManager/InstallHelpers.d.ts +1 -0
- package/lib/logic/operations/OperationExecutionRecord.d.ts +9 -7
- package/lib/logic/operations/OperationStatus.d.ts +5 -1
- package/lib/logic/pnpm/IPnpmfile.d.ts +16 -0
- package/lib/logic/pnpm/PnpmProjectShrinkwrapFile.d.ts +7 -0
- package/lib/logic/pnpm/PnpmShrinkwrapFile.d.ts +17 -0
- package/lib/logic/pnpm/SplitWorkspaceGlobalPnpmfileShim.d.ts +3 -0
- package/lib/logic/pnpm/SplitWorkspaceGlobalPnpmfileShim.js +1 -0
- package/lib/logic/pnpm/SplitWorkspacePnpmfileConfiguration.d.ts +23 -0
- package/lib/logic/pnpm/SplitWorkspacePnpmfileConfiguration.js +1 -0
- package/lib/logic/selectors/SplitWorkspaceProjectSelectorParser.d.ts +10 -0
- package/lib/logic/selectors/SplitWorkspaceProjectSelectorParser.js +1 -0
- package/lib/logic/versionMismatch/VersionMismatchFinderProject.d.ts +2 -0
- package/lib/utilities/PathConstants.d.ts +1 -0
- package/lib/utilities/Utilities.d.ts +6 -0
- package/lib/utilities/npmrcUtilities.d.ts +1 -1
- package/lib/utilities/objectUtilities.d.ts +5 -0
- package/lib-shim/index.d.ts.map +1 -1
- package/lib-shim/index.js.map +1 -1
- package/lib-shim/loader.d.ts.map +1 -1
- package/lib-shim/loader.js +8 -6
- package/lib-shim/loader.js.map +1 -1
- package/package.json +9 -10
package/dist/rush-lib.d.ts
CHANGED
|
@@ -132,6 +132,55 @@ export declare class ApprovedPackagesPolicy {
|
|
|
132
132
|
constructor(rushConfiguration: RushConfiguration, rushConfigurationJson: IRushConfigurationJson);
|
|
133
133
|
}
|
|
134
134
|
|
|
135
|
+
/**
|
|
136
|
+
* A base class for flag file.
|
|
137
|
+
* @internal
|
|
138
|
+
*/
|
|
139
|
+
export declare class _BaseFlag<T extends object = JsonObject> {
|
|
140
|
+
/**
|
|
141
|
+
* Flag file path
|
|
142
|
+
*/
|
|
143
|
+
readonly path: string;
|
|
144
|
+
/**
|
|
145
|
+
* Content of the flag
|
|
146
|
+
*/
|
|
147
|
+
protected _state: T;
|
|
148
|
+
/**
|
|
149
|
+
* Whether the current state is modified
|
|
150
|
+
*/
|
|
151
|
+
protected _isModified: boolean;
|
|
152
|
+
/**
|
|
153
|
+
* Creates a new flag file
|
|
154
|
+
* @param folderPath - the folder that this flag is managing
|
|
155
|
+
* @param state - optional, the state that should be managed or compared
|
|
156
|
+
*/
|
|
157
|
+
constructor(folderPath: string, state?: Partial<T>);
|
|
158
|
+
/**
|
|
159
|
+
* Returns true if the file exists and the contents match the current state.
|
|
160
|
+
*/
|
|
161
|
+
isValid(): boolean;
|
|
162
|
+
/**
|
|
163
|
+
* Writes the flag file to disk with the current state
|
|
164
|
+
*/
|
|
165
|
+
create(): void;
|
|
166
|
+
/**
|
|
167
|
+
* Merge new data into current state by "merge"
|
|
168
|
+
*/
|
|
169
|
+
mergeFromObject(data: JsonObject): void;
|
|
170
|
+
/**
|
|
171
|
+
* Writes the flag file to disk with the current state if modified
|
|
172
|
+
*/
|
|
173
|
+
saveIfModified(): void;
|
|
174
|
+
/**
|
|
175
|
+
* Removes the flag file
|
|
176
|
+
*/
|
|
177
|
+
clear(): void;
|
|
178
|
+
/**
|
|
179
|
+
* Returns Name of the flag file
|
|
180
|
+
*/
|
|
181
|
+
protected get flagName(): string;
|
|
182
|
+
}
|
|
183
|
+
|
|
135
184
|
/**
|
|
136
185
|
* Use this class to load and save the "common/config/rush/build-cache.json" config file.
|
|
137
186
|
* This file provides configuration options for cached project build output.
|
|
@@ -377,8 +426,8 @@ export declare class CredentialCache {
|
|
|
377
426
|
* @beta
|
|
378
427
|
*/
|
|
379
428
|
export declare enum CustomTipId {
|
|
380
|
-
TIP_PNPM_UNEXPECTED_STORE = "TIP_PNPM_UNEXPECTED_STORE",
|
|
381
429
|
TIP_RUSH_INCONSISTENT_VERSIONS = "TIP_RUSH_INCONSISTENT_VERSIONS",
|
|
430
|
+
TIP_PNPM_UNEXPECTED_STORE = "TIP_PNPM_UNEXPECTED_STORE",
|
|
382
431
|
TIP_PNPM_NO_MATCHING_VERSION = "TIP_PNPM_NO_MATCHING_VERSION",
|
|
383
432
|
TIP_PNPM_NO_MATCHING_VERSION_INSIDE_WORKSPACE = "TIP_PNPM_NO_MATCHING_VERSION_INSIDE_WORKSPACE",
|
|
384
433
|
TIP_PNPM_PEER_DEP_ISSUES = "TIP_PNPM_PEER_DEP_ISSUES",
|
|
@@ -396,12 +445,7 @@ export declare enum CustomTipId {
|
|
|
396
445
|
*/
|
|
397
446
|
export declare class CustomTipsConfiguration {
|
|
398
447
|
private static _jsonSchema;
|
|
399
|
-
|
|
400
|
-
private readonly _jsonFileName;
|
|
401
|
-
/**
|
|
402
|
-
* The JSON settings loaded from `custom-tips.json`.
|
|
403
|
-
*/
|
|
404
|
-
readonly configuration: Readonly<ICustomTipsJson>;
|
|
448
|
+
readonly providedCustomTipsByTipId: ReadonlyMap<CustomTipId, ICustomTipItemJson>;
|
|
405
449
|
/**
|
|
406
450
|
* A registry mapping custom tip IDs to their corresponding metadata.
|
|
407
451
|
*
|
|
@@ -422,7 +466,7 @@ export declare class CustomTipsConfiguration {
|
|
|
422
466
|
* See {@link ICustomTipInfo} for the structure of the metadata.
|
|
423
467
|
*/
|
|
424
468
|
static customTipRegistry: Readonly<Record<CustomTipId, ICustomTipInfo>>;
|
|
425
|
-
constructor(
|
|
469
|
+
constructor(configFilePath: string);
|
|
426
470
|
/**
|
|
427
471
|
* If custom-tips.json defines a tip for the specified tipId,
|
|
428
472
|
* display the tip on the terminal.
|
|
@@ -452,7 +496,6 @@ export declare class CustomTipsConfiguration {
|
|
|
452
496
|
* @internal
|
|
453
497
|
*/
|
|
454
498
|
_showErrorTip(terminal: ITerminal, tipId: CustomTipId): void;
|
|
455
|
-
private _formatMessageHeader;
|
|
456
499
|
private _writeMessageWithPipes;
|
|
457
500
|
}
|
|
458
501
|
|
|
@@ -798,7 +841,7 @@ export declare const EnvironmentVariableNames: {
|
|
|
798
841
|
* Events happen during Rush runs.
|
|
799
842
|
* @beta
|
|
800
843
|
*/
|
|
801
|
-
|
|
844
|
+
declare enum Event_2 {
|
|
802
845
|
/**
|
|
803
846
|
* Pre Rush install event
|
|
804
847
|
*/
|
|
@@ -816,6 +859,7 @@ export declare enum Event {
|
|
|
816
859
|
*/
|
|
817
860
|
postRushBuild = 4
|
|
818
861
|
}
|
|
862
|
+
export { Event_2 as Event }
|
|
819
863
|
|
|
820
864
|
/**
|
|
821
865
|
* This class represents Rush event hooks configured for this repo.
|
|
@@ -833,7 +877,7 @@ export declare class EventHooks {
|
|
|
833
877
|
* Return all the scripts associated with the specified event.
|
|
834
878
|
* @param event - Rush event
|
|
835
879
|
*/
|
|
836
|
-
get(event:
|
|
880
|
+
get(event: Event_2): string[];
|
|
837
881
|
}
|
|
838
882
|
|
|
839
883
|
/**
|
|
@@ -1289,6 +1333,11 @@ export declare interface IExperimentsJson {
|
|
|
1289
1333
|
* in common/config/rush/command-line.json.
|
|
1290
1334
|
*/
|
|
1291
1335
|
phasedCommands?: boolean;
|
|
1336
|
+
/**
|
|
1337
|
+
* If true, rush install or rush update implicitly specify --ignore-scripts during pnpm install,
|
|
1338
|
+
* and run install lifecycle scripts by pnpm rebuild --pending after pnpm install successfully.
|
|
1339
|
+
*/
|
|
1340
|
+
deferredInstallationScripts?: boolean;
|
|
1292
1341
|
/**
|
|
1293
1342
|
* If true, perform a clean install after when running `rush install` or `rush update` if the
|
|
1294
1343
|
* `.npmrc` file has changed since the last install.
|
|
@@ -1368,6 +1417,51 @@ declare interface IIndividualVersionJson extends IVersionPolicyJson {
|
|
|
1368
1417
|
lockedMajor?: number;
|
|
1369
1418
|
}
|
|
1370
1419
|
|
|
1420
|
+
/**
|
|
1421
|
+
* This represents the JSON data structure for the "last-install.flag" file.
|
|
1422
|
+
* @internal
|
|
1423
|
+
*/
|
|
1424
|
+
export declare interface _ILastInstallFlagJson {
|
|
1425
|
+
/**
|
|
1426
|
+
* Current node version
|
|
1427
|
+
*/
|
|
1428
|
+
node: string;
|
|
1429
|
+
/**
|
|
1430
|
+
* Current package manager name
|
|
1431
|
+
*/
|
|
1432
|
+
packageManager: PackageManagerName;
|
|
1433
|
+
/**
|
|
1434
|
+
* Current package manager version
|
|
1435
|
+
*/
|
|
1436
|
+
packageManagerVersion: string;
|
|
1437
|
+
/**
|
|
1438
|
+
* Current rush json folder
|
|
1439
|
+
*/
|
|
1440
|
+
rushJsonFolder: string;
|
|
1441
|
+
/**
|
|
1442
|
+
* The content of package.json, used in the flag file of autoinstaller
|
|
1443
|
+
*/
|
|
1444
|
+
packageJson?: IPackageJson;
|
|
1445
|
+
/**
|
|
1446
|
+
* Same with pnpmOptions.pnpmStorePath in rush.json
|
|
1447
|
+
*/
|
|
1448
|
+
storePath?: string;
|
|
1449
|
+
/**
|
|
1450
|
+
* True when "useWorkspaces" is true in rush.json
|
|
1451
|
+
*/
|
|
1452
|
+
workspaces?: true;
|
|
1453
|
+
/**
|
|
1454
|
+
* True when user explicitly specify "--ignore-scripts" CLI parameter or deferredInstallationScripts
|
|
1455
|
+
*/
|
|
1456
|
+
ignoreScripts?: true;
|
|
1457
|
+
/**
|
|
1458
|
+
* When specified, it is a list of selected projects during partial install
|
|
1459
|
+
* It is undefined when full install
|
|
1460
|
+
*/
|
|
1461
|
+
selectedProjectNames?: string[];
|
|
1462
|
+
[key: string]: unknown;
|
|
1463
|
+
}
|
|
1464
|
+
|
|
1371
1465
|
/**
|
|
1372
1466
|
* Options to pass to the rush "launch" functions.
|
|
1373
1467
|
*
|
|
@@ -1955,6 +2049,7 @@ declare interface IRushConfigurationProjectJson {
|
|
|
1955
2049
|
skipRushCheck?: boolean;
|
|
1956
2050
|
publishFolder?: string;
|
|
1957
2051
|
tags?: string[];
|
|
2052
|
+
splitWorkspace?: boolean;
|
|
1958
2053
|
}
|
|
1959
2054
|
|
|
1960
2055
|
/**
|
|
@@ -1979,6 +2074,16 @@ declare interface IRushConfigurationProjectOptions {
|
|
|
1979
2074
|
allowedProjectTags: Set<string> | undefined;
|
|
1980
2075
|
}
|
|
1981
2076
|
|
|
2077
|
+
/**
|
|
2078
|
+
* The filter parameters to search from all projects.
|
|
2079
|
+
*/
|
|
2080
|
+
declare interface IRushConfigurationProjectsFilter {
|
|
2081
|
+
/**
|
|
2082
|
+
* If true, filter out projects that specify splitWorkspace as true.
|
|
2083
|
+
*/
|
|
2084
|
+
splitWorkspace: boolean;
|
|
2085
|
+
}
|
|
2086
|
+
|
|
1982
2087
|
/**
|
|
1983
2088
|
* Part of IRushConfigurationJson.
|
|
1984
2089
|
*/
|
|
@@ -2269,19 +2374,9 @@ export declare interface _IYarnOptionsJson extends IPackageManagerOptionsJsonBas
|
|
|
2269
2374
|
* it can invalidate the last install.
|
|
2270
2375
|
* @internal
|
|
2271
2376
|
*/
|
|
2272
|
-
export declare class _LastInstallFlag {
|
|
2273
|
-
private _state;
|
|
2274
|
-
/**
|
|
2275
|
-
* Returns the full path to the flag file
|
|
2276
|
-
*/
|
|
2277
|
-
readonly path: string;
|
|
2278
|
-
/**
|
|
2279
|
-
* Creates a new LastInstall flag
|
|
2280
|
-
* @param folderPath - the folder that this flag is managing
|
|
2281
|
-
* @param state - optional, the state that should be managed or compared
|
|
2282
|
-
*/
|
|
2283
|
-
constructor(folderPath: string, state?: JsonObject);
|
|
2377
|
+
export declare class _LastInstallFlag extends _BaseFlag<_ILastInstallFlagJson> {
|
|
2284
2378
|
/**
|
|
2379
|
+
* @override
|
|
2285
2380
|
* Returns true if the file exists and the contents match the current state.
|
|
2286
2381
|
*/
|
|
2287
2382
|
isValid(options?: _ILockfileValidityCheckOptions): boolean;
|
|
@@ -2295,14 +2390,6 @@ export declare class _LastInstallFlag {
|
|
|
2295
2390
|
rushVerb: string;
|
|
2296
2391
|
}): boolean;
|
|
2297
2392
|
private _isValid;
|
|
2298
|
-
/**
|
|
2299
|
-
* Writes the flag file to disk with the current state
|
|
2300
|
-
*/
|
|
2301
|
-
create(): void;
|
|
2302
|
-
/**
|
|
2303
|
-
* Removes the flag file
|
|
2304
|
-
*/
|
|
2305
|
-
clear(): void;
|
|
2306
2393
|
/**
|
|
2307
2394
|
* Returns the name of the flag file
|
|
2308
2395
|
*/
|
|
@@ -2614,9 +2701,13 @@ export declare class _OperationStateFile {
|
|
|
2614
2701
|
*/
|
|
2615
2702
|
export declare enum OperationStatus {
|
|
2616
2703
|
/**
|
|
2617
|
-
* The Operation is
|
|
2704
|
+
* The Operation is ready to execute. All its dependencies have succeeded.
|
|
2618
2705
|
*/
|
|
2619
2706
|
Ready = "READY",
|
|
2707
|
+
/**
|
|
2708
|
+
* The Operation is waiting for one or more dependencies to complete.
|
|
2709
|
+
*/
|
|
2710
|
+
Waiting = "WAITING",
|
|
2620
2711
|
/**
|
|
2621
2712
|
* The Operation is Queued
|
|
2622
2713
|
*/
|
|
@@ -3206,6 +3297,8 @@ export declare class RushConfiguration {
|
|
|
3206
3297
|
private _projects;
|
|
3207
3298
|
private _projectsByName;
|
|
3208
3299
|
private _projectsByTag;
|
|
3300
|
+
private _filteredProjectsCache;
|
|
3301
|
+
private _hasSplitWorkspaceProject;
|
|
3209
3302
|
private _commonVersionsConfigurationsByVariant;
|
|
3210
3303
|
/**
|
|
3211
3304
|
* The name of the package manager being used to install dependencies
|
|
@@ -3260,6 +3353,12 @@ export declare class RushConfiguration {
|
|
|
3260
3353
|
* Example: `C:\MyRepo\common\temp`
|
|
3261
3354
|
*/
|
|
3262
3355
|
readonly commonTempFolder: string;
|
|
3356
|
+
/**
|
|
3357
|
+
* The folder where temporary files will be stored. This is always a subfolder called "temp"
|
|
3358
|
+
* under the common folder.
|
|
3359
|
+
* Example: `C:\MyRepo\common\temp-split`
|
|
3360
|
+
*/
|
|
3361
|
+
readonly commonTempSplitFolder: string;
|
|
3263
3362
|
/**
|
|
3264
3363
|
* The folder where automation scripts are stored. This is always a subfolder called "scripts"
|
|
3265
3364
|
* under the common folder.
|
|
@@ -3314,6 +3413,21 @@ export declare class RushConfiguration {
|
|
|
3314
3413
|
* or `C:\MyRepo\common\temp\pnpm-lock-preinstall.yaml`
|
|
3315
3414
|
*/
|
|
3316
3415
|
readonly tempShrinkwrapPreinstallFilename: string;
|
|
3416
|
+
/**
|
|
3417
|
+
* The filename (without any path) of the shrinkwrap file for split workspace that is used by the package manager.
|
|
3418
|
+
* @remarks
|
|
3419
|
+
* This property merely reports the filename; the file itself may not actually exist.
|
|
3420
|
+
* Example: `pnpm-lock.yaml`
|
|
3421
|
+
*/
|
|
3422
|
+
readonly splitWorkspaceShrinkwrapFilename: string;
|
|
3423
|
+
/**
|
|
3424
|
+
* The full path of the temporary shrinkwrap file for split workspace that is used during
|
|
3425
|
+
* "rush install". This file may get rewritten by the package manager during installation.
|
|
3426
|
+
* @remarks
|
|
3427
|
+
* This property merely reports the filename; the file itself may not actually exist.
|
|
3428
|
+
* Example: `C:\MyRepo\common\temp-split\pnpm-lock.yaml`
|
|
3429
|
+
*/
|
|
3430
|
+
readonly tempSplitWorkspaceShrinkwrapFilename: string;
|
|
3317
3431
|
/**
|
|
3318
3432
|
* The filename of the variant dependency data file. By default this is
|
|
3319
3433
|
* called 'current-variant.json' resides in the Rush common folder.
|
|
@@ -3580,6 +3694,11 @@ export declare class RushConfiguration {
|
|
|
3580
3694
|
* @beta
|
|
3581
3695
|
*/
|
|
3582
3696
|
get projectsByTag(): ReadonlyMap<string, ReadonlySet<RushConfigurationProject>>;
|
|
3697
|
+
/**
|
|
3698
|
+
* Search for projects according to filter
|
|
3699
|
+
* @beta
|
|
3700
|
+
*/
|
|
3701
|
+
getFilteredProjects(filter: IRushConfigurationProjectsFilter): RushConfigurationProject[];
|
|
3583
3702
|
/**
|
|
3584
3703
|
* Settings from the common-versions.json config file.
|
|
3585
3704
|
* @remarks
|
|
@@ -3598,6 +3717,10 @@ export declare class RushConfiguration {
|
|
|
3598
3717
|
* or "rush update".
|
|
3599
3718
|
*/
|
|
3600
3719
|
get currentInstalledVariant(): string | undefined;
|
|
3720
|
+
/**
|
|
3721
|
+
* Is there any split workspace project.
|
|
3722
|
+
*/
|
|
3723
|
+
get hasSplitWorkspaceProject(): boolean;
|
|
3601
3724
|
/**
|
|
3602
3725
|
* Gets the path to the common-versions.json config file for a specific variant.
|
|
3603
3726
|
* @param variant - The name of the current variant in use by the active command.
|
|
@@ -3630,6 +3753,11 @@ export declare class RushConfiguration {
|
|
|
3630
3753
|
* @param variant - The name of the current variant in use by the active command.
|
|
3631
3754
|
*/
|
|
3632
3755
|
getCommittedShrinkwrapFilename(variant?: string | undefined): string;
|
|
3756
|
+
/**
|
|
3757
|
+
* Gets the committed shrinkwrap file name for split workspace.
|
|
3758
|
+
* @param variant - The name of the current variant in use by the active command.
|
|
3759
|
+
*/
|
|
3760
|
+
getCommittedSplitWorkspaceShrinkwrapFilename(): string;
|
|
3633
3761
|
/**
|
|
3634
3762
|
* Gets the absolute path for "pnpmfile.js" for a specific variant.
|
|
3635
3763
|
* @param variant - The name of the current variant in use by the active command.
|
|
@@ -3665,6 +3793,12 @@ export declare class RushConfiguration {
|
|
|
3665
3793
|
*/
|
|
3666
3794
|
tryGetProjectForPath(currentFolderPath: string): RushConfigurationProject | undefined;
|
|
3667
3795
|
private _getVariantConfigFolderPath;
|
|
3796
|
+
/**
|
|
3797
|
+
* Split workspace can only works on PNPM with "useWorkspaces" enabled.
|
|
3798
|
+
* The workspace project can NOT depend on a split workspace project.
|
|
3799
|
+
* The split workspace project CAN depend on a workspace project.
|
|
3800
|
+
*/
|
|
3801
|
+
private _validateSplitWorkspaceRelationships;
|
|
3668
3802
|
}
|
|
3669
3803
|
|
|
3670
3804
|
/**
|
|
@@ -3780,6 +3914,11 @@ export declare class RushConfigurationProject {
|
|
|
3780
3914
|
* @beta
|
|
3781
3915
|
*/
|
|
3782
3916
|
readonly tags: ReadonlySet<string>;
|
|
3917
|
+
/**
|
|
3918
|
+
* Whether this project is a split workspace project.
|
|
3919
|
+
* @beta
|
|
3920
|
+
*/
|
|
3921
|
+
readonly splitWorkspace: boolean;
|
|
3783
3922
|
/** @internal */
|
|
3784
3923
|
constructor(options: IRushConfigurationProjectOptions);
|
|
3785
3924
|
/**
|
|
@@ -3889,6 +4028,12 @@ export declare class RushConstants {
|
|
|
3889
4028
|
* Example: `C:\MyRepo\common\temp`
|
|
3890
4029
|
*/
|
|
3891
4030
|
static readonly rushTempFolderName: string;
|
|
4031
|
+
/**
|
|
4032
|
+
* The folder name ("temp-split") under the common folder, or under the .rush folder in each project's directory where
|
|
4033
|
+
* temporary files will be stored.
|
|
4034
|
+
* Example: `C:\MyRepo\common\temp-split`
|
|
4035
|
+
*/
|
|
4036
|
+
static readonly rushTempSplitFolderName: string;
|
|
3892
4037
|
/**
|
|
3893
4038
|
* The folder name ("projects") where temporary projects will be stored.
|
|
3894
4039
|
* Example: `C:\MyRepo\common\temp\projects`
|
package/dist/tsdoc-metadata.json
CHANGED
|
@@ -39,8 +39,8 @@ export interface ICustomTipItemJson {
|
|
|
39
39
|
* @beta
|
|
40
40
|
*/
|
|
41
41
|
export declare enum CustomTipId {
|
|
42
|
-
TIP_PNPM_UNEXPECTED_STORE = "TIP_PNPM_UNEXPECTED_STORE",
|
|
43
42
|
TIP_RUSH_INCONSISTENT_VERSIONS = "TIP_RUSH_INCONSISTENT_VERSIONS",
|
|
43
|
+
TIP_PNPM_UNEXPECTED_STORE = "TIP_PNPM_UNEXPECTED_STORE",
|
|
44
44
|
TIP_PNPM_NO_MATCHING_VERSION = "TIP_PNPM_NO_MATCHING_VERSION",
|
|
45
45
|
TIP_PNPM_NO_MATCHING_VERSION_INSIDE_WORKSPACE = "TIP_PNPM_NO_MATCHING_VERSION_INSIDE_WORKSPACE",
|
|
46
46
|
TIP_PNPM_PEER_DEP_ISSUES = "TIP_PNPM_PEER_DEP_ISSUES",
|
|
@@ -104,6 +104,8 @@ export interface ICustomTipInfo {
|
|
|
104
104
|
*/
|
|
105
105
|
isMatch?: (str: string) => boolean;
|
|
106
106
|
}
|
|
107
|
+
export declare const RUSH_CUSTOM_TIPS: Readonly<Record<`TIP_RUSH_${string}` & CustomTipId, ICustomTipInfo>>;
|
|
108
|
+
export declare const PNPM_CUSTOM_TIPS: Readonly<Record<`TIP_PNPM_${string}` & CustomTipId, ICustomTipInfo>>;
|
|
107
109
|
/**
|
|
108
110
|
* Used to access the `common/config/rush/custom-tips.json` config file,
|
|
109
111
|
* which allows repo maintainers to configure extra details to be printed alongside
|
|
@@ -112,12 +114,7 @@ export interface ICustomTipInfo {
|
|
|
112
114
|
*/
|
|
113
115
|
export declare class CustomTipsConfiguration {
|
|
114
116
|
private static _jsonSchema;
|
|
115
|
-
|
|
116
|
-
private readonly _jsonFileName;
|
|
117
|
-
/**
|
|
118
|
-
* The JSON settings loaded from `custom-tips.json`.
|
|
119
|
-
*/
|
|
120
|
-
readonly configuration: Readonly<ICustomTipsJson>;
|
|
117
|
+
readonly providedCustomTipsByTipId: ReadonlyMap<CustomTipId, ICustomTipItemJson>;
|
|
121
118
|
/**
|
|
122
119
|
* A registry mapping custom tip IDs to their corresponding metadata.
|
|
123
120
|
*
|
|
@@ -138,7 +135,7 @@ export declare class CustomTipsConfiguration {
|
|
|
138
135
|
* See {@link ICustomTipInfo} for the structure of the metadata.
|
|
139
136
|
*/
|
|
140
137
|
static customTipRegistry: Readonly<Record<CustomTipId, ICustomTipInfo>>;
|
|
141
|
-
constructor(
|
|
138
|
+
constructor(configFilePath: string);
|
|
142
139
|
/**
|
|
143
140
|
* If custom-tips.json defines a tip for the specified tipId,
|
|
144
141
|
* display the tip on the terminal.
|
|
@@ -168,7 +165,6 @@ export declare class CustomTipsConfiguration {
|
|
|
168
165
|
* @internal
|
|
169
166
|
*/
|
|
170
167
|
_showErrorTip(terminal: ITerminal, tipId: CustomTipId): void;
|
|
171
|
-
private _formatMessageHeader;
|
|
172
168
|
private _writeMessageWithPipes;
|
|
173
169
|
}
|
|
174
170
|
//# sourceMappingURL=CustomTipsConfiguration.d.ts.map
|
|
@@ -41,6 +41,11 @@ export interface IExperimentsJson {
|
|
|
41
41
|
* in common/config/rush/command-line.json.
|
|
42
42
|
*/
|
|
43
43
|
phasedCommands?: boolean;
|
|
44
|
+
/**
|
|
45
|
+
* If true, rush install or rush update implicitly specify --ignore-scripts during pnpm install,
|
|
46
|
+
* and run install lifecycle scripts by pnpm rebuild --pending after pnpm install successfully.
|
|
47
|
+
*/
|
|
48
|
+
deferredInstallationScripts?: boolean;
|
|
44
49
|
/**
|
|
45
50
|
* If true, perform a clean install after when running `rush install` or `rush update` if the
|
|
46
51
|
* `.npmrc` file has changed since the last install.
|
|
@@ -1,6 +1,52 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { IPackageJson } from '@rushstack/node-core-library';
|
|
2
|
+
import { BaseFlag } from './base/BaseFlag';
|
|
3
|
+
import { PackageManagerName } from './packageManager/PackageManager';
|
|
2
4
|
import { RushConfiguration } from './RushConfiguration';
|
|
3
5
|
export declare const LAST_INSTALL_FLAG_FILE_NAME: string;
|
|
6
|
+
/**
|
|
7
|
+
* This represents the JSON data structure for the "last-install.flag" file.
|
|
8
|
+
* @internal
|
|
9
|
+
*/
|
|
10
|
+
export interface ILastInstallFlagJson {
|
|
11
|
+
/**
|
|
12
|
+
* Current node version
|
|
13
|
+
*/
|
|
14
|
+
node: string;
|
|
15
|
+
/**
|
|
16
|
+
* Current package manager name
|
|
17
|
+
*/
|
|
18
|
+
packageManager: PackageManagerName;
|
|
19
|
+
/**
|
|
20
|
+
* Current package manager version
|
|
21
|
+
*/
|
|
22
|
+
packageManagerVersion: string;
|
|
23
|
+
/**
|
|
24
|
+
* Current rush json folder
|
|
25
|
+
*/
|
|
26
|
+
rushJsonFolder: string;
|
|
27
|
+
/**
|
|
28
|
+
* The content of package.json, used in the flag file of autoinstaller
|
|
29
|
+
*/
|
|
30
|
+
packageJson?: IPackageJson;
|
|
31
|
+
/**
|
|
32
|
+
* Same with pnpmOptions.pnpmStorePath in rush.json
|
|
33
|
+
*/
|
|
34
|
+
storePath?: string;
|
|
35
|
+
/**
|
|
36
|
+
* True when "useWorkspaces" is true in rush.json
|
|
37
|
+
*/
|
|
38
|
+
workspaces?: true;
|
|
39
|
+
/**
|
|
40
|
+
* True when user explicitly specify "--ignore-scripts" CLI parameter or deferredInstallationScripts
|
|
41
|
+
*/
|
|
42
|
+
ignoreScripts?: true;
|
|
43
|
+
/**
|
|
44
|
+
* When specified, it is a list of selected projects during partial install
|
|
45
|
+
* It is undefined when full install
|
|
46
|
+
*/
|
|
47
|
+
selectedProjectNames?: string[];
|
|
48
|
+
[key: string]: unknown;
|
|
49
|
+
}
|
|
4
50
|
/**
|
|
5
51
|
* @internal
|
|
6
52
|
*/
|
|
@@ -15,19 +61,9 @@ export interface ILockfileValidityCheckOptions {
|
|
|
15
61
|
* it can invalidate the last install.
|
|
16
62
|
* @internal
|
|
17
63
|
*/
|
|
18
|
-
export declare class LastInstallFlag {
|
|
19
|
-
private _state;
|
|
20
|
-
/**
|
|
21
|
-
* Returns the full path to the flag file
|
|
22
|
-
*/
|
|
23
|
-
readonly path: string;
|
|
24
|
-
/**
|
|
25
|
-
* Creates a new LastInstall flag
|
|
26
|
-
* @param folderPath - the folder that this flag is managing
|
|
27
|
-
* @param state - optional, the state that should be managed or compared
|
|
28
|
-
*/
|
|
29
|
-
constructor(folderPath: string, state?: JsonObject);
|
|
64
|
+
export declare class LastInstallFlag extends BaseFlag<ILastInstallFlagJson> {
|
|
30
65
|
/**
|
|
66
|
+
* @override
|
|
31
67
|
* Returns true if the file exists and the contents match the current state.
|
|
32
68
|
*/
|
|
33
69
|
isValid(options?: ILockfileValidityCheckOptions): boolean;
|
|
@@ -41,14 +77,6 @@ export declare class LastInstallFlag {
|
|
|
41
77
|
rushVerb: string;
|
|
42
78
|
}): boolean;
|
|
43
79
|
private _isValid;
|
|
44
|
-
/**
|
|
45
|
-
* Writes the flag file to disk with the current state
|
|
46
|
-
*/
|
|
47
|
-
create(): void;
|
|
48
|
-
/**
|
|
49
|
-
* Removes the flag file
|
|
50
|
-
*/
|
|
51
|
-
clear(): void;
|
|
52
80
|
/**
|
|
53
81
|
* Returns the name of the flag file
|
|
54
82
|
*/
|
|
@@ -69,5 +97,14 @@ export declare class LastInstallFlagFactory {
|
|
|
69
97
|
* @internal
|
|
70
98
|
*/
|
|
71
99
|
static getCommonTempFlag(rushConfiguration: RushConfiguration, extraState?: Record<string, string>): LastInstallFlag;
|
|
100
|
+
/**
|
|
101
|
+
* Gets the LastInstall flag and sets the current state. This state is used to compare
|
|
102
|
+
* against the last-known-good state tracked by the LastInstall flag.
|
|
103
|
+
* @param rushConfiguration - the configuration of the Rush repo to get the install
|
|
104
|
+
* state from
|
|
105
|
+
*
|
|
106
|
+
* @internal
|
|
107
|
+
*/
|
|
108
|
+
static getCommonTempSplitFlag(rushConfiguration: RushConfiguration): LastInstallFlag;
|
|
72
109
|
}
|
|
73
110
|
//# sourceMappingURL=LastInstallFlag.d.ts.map
|
|
@@ -1,16 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { RushConfiguration } from './RushConfiguration';
|
|
1
|
+
import { BaseFlag } from './base/BaseFlag';
|
|
2
|
+
import type { RushConfiguration } from './RushConfiguration';
|
|
3
3
|
export declare const LAST_LINK_FLAG_FILE_NAME: string;
|
|
4
4
|
/**
|
|
5
5
|
* A helper class for managing the last-link flag, which is persistent and
|
|
6
6
|
* indicates that linking was completed successfully.
|
|
7
7
|
* @internal
|
|
8
8
|
*/
|
|
9
|
-
export declare class LastLinkFlag extends
|
|
10
|
-
/**
|
|
11
|
-
* @override
|
|
12
|
-
*/
|
|
13
|
-
isValid(): boolean;
|
|
9
|
+
export declare class LastLinkFlag extends BaseFlag {
|
|
14
10
|
/**
|
|
15
11
|
* @override
|
|
16
12
|
*/
|
|
@@ -118,6 +118,15 @@ export interface IRushConfigurationJson {
|
|
|
118
118
|
export interface ICurrentVariantJson {
|
|
119
119
|
variant: string | JsonNull;
|
|
120
120
|
}
|
|
121
|
+
/**
|
|
122
|
+
* The filter parameters to search from all projects.
|
|
123
|
+
*/
|
|
124
|
+
export interface IRushConfigurationProjectsFilter {
|
|
125
|
+
/**
|
|
126
|
+
* If true, filter out projects that specify splitWorkspace as true.
|
|
127
|
+
*/
|
|
128
|
+
splitWorkspace: boolean;
|
|
129
|
+
}
|
|
121
130
|
/**
|
|
122
131
|
* Options for `RushConfiguration.tryFindRushJsonLocation`.
|
|
123
132
|
* @public
|
|
@@ -144,6 +153,8 @@ export declare class RushConfiguration {
|
|
|
144
153
|
private _projects;
|
|
145
154
|
private _projectsByName;
|
|
146
155
|
private _projectsByTag;
|
|
156
|
+
private _filteredProjectsCache;
|
|
157
|
+
private _hasSplitWorkspaceProject;
|
|
147
158
|
private _commonVersionsConfigurationsByVariant;
|
|
148
159
|
/**
|
|
149
160
|
* The name of the package manager being used to install dependencies
|
|
@@ -198,6 +209,12 @@ export declare class RushConfiguration {
|
|
|
198
209
|
* Example: `C:\MyRepo\common\temp`
|
|
199
210
|
*/
|
|
200
211
|
readonly commonTempFolder: string;
|
|
212
|
+
/**
|
|
213
|
+
* The folder where temporary files will be stored. This is always a subfolder called "temp"
|
|
214
|
+
* under the common folder.
|
|
215
|
+
* Example: `C:\MyRepo\common\temp-split`
|
|
216
|
+
*/
|
|
217
|
+
readonly commonTempSplitFolder: string;
|
|
201
218
|
/**
|
|
202
219
|
* The folder where automation scripts are stored. This is always a subfolder called "scripts"
|
|
203
220
|
* under the common folder.
|
|
@@ -252,6 +269,21 @@ export declare class RushConfiguration {
|
|
|
252
269
|
* or `C:\MyRepo\common\temp\pnpm-lock-preinstall.yaml`
|
|
253
270
|
*/
|
|
254
271
|
readonly tempShrinkwrapPreinstallFilename: string;
|
|
272
|
+
/**
|
|
273
|
+
* The filename (without any path) of the shrinkwrap file for split workspace that is used by the package manager.
|
|
274
|
+
* @remarks
|
|
275
|
+
* This property merely reports the filename; the file itself may not actually exist.
|
|
276
|
+
* Example: `pnpm-lock.yaml`
|
|
277
|
+
*/
|
|
278
|
+
readonly splitWorkspaceShrinkwrapFilename: string;
|
|
279
|
+
/**
|
|
280
|
+
* The full path of the temporary shrinkwrap file for split workspace that is used during
|
|
281
|
+
* "rush install". This file may get rewritten by the package manager during installation.
|
|
282
|
+
* @remarks
|
|
283
|
+
* This property merely reports the filename; the file itself may not actually exist.
|
|
284
|
+
* Example: `C:\MyRepo\common\temp-split\pnpm-lock.yaml`
|
|
285
|
+
*/
|
|
286
|
+
readonly tempSplitWorkspaceShrinkwrapFilename: string;
|
|
255
287
|
/**
|
|
256
288
|
* The filename of the variant dependency data file. By default this is
|
|
257
289
|
* called 'current-variant.json' resides in the Rush common folder.
|
|
@@ -518,6 +550,11 @@ export declare class RushConfiguration {
|
|
|
518
550
|
* @beta
|
|
519
551
|
*/
|
|
520
552
|
get projectsByTag(): ReadonlyMap<string, ReadonlySet<RushConfigurationProject>>;
|
|
553
|
+
/**
|
|
554
|
+
* Search for projects according to filter
|
|
555
|
+
* @beta
|
|
556
|
+
*/
|
|
557
|
+
getFilteredProjects(filter: IRushConfigurationProjectsFilter): RushConfigurationProject[];
|
|
521
558
|
/**
|
|
522
559
|
* Settings from the common-versions.json config file.
|
|
523
560
|
* @remarks
|
|
@@ -536,6 +573,10 @@ export declare class RushConfiguration {
|
|
|
536
573
|
* or "rush update".
|
|
537
574
|
*/
|
|
538
575
|
get currentInstalledVariant(): string | undefined;
|
|
576
|
+
/**
|
|
577
|
+
* Is there any split workspace project.
|
|
578
|
+
*/
|
|
579
|
+
get hasSplitWorkspaceProject(): boolean;
|
|
539
580
|
/**
|
|
540
581
|
* Gets the path to the common-versions.json config file for a specific variant.
|
|
541
582
|
* @param variant - The name of the current variant in use by the active command.
|
|
@@ -568,6 +609,11 @@ export declare class RushConfiguration {
|
|
|
568
609
|
* @param variant - The name of the current variant in use by the active command.
|
|
569
610
|
*/
|
|
570
611
|
getCommittedShrinkwrapFilename(variant?: string | undefined): string;
|
|
612
|
+
/**
|
|
613
|
+
* Gets the committed shrinkwrap file name for split workspace.
|
|
614
|
+
* @param variant - The name of the current variant in use by the active command.
|
|
615
|
+
*/
|
|
616
|
+
getCommittedSplitWorkspaceShrinkwrapFilename(): string;
|
|
571
617
|
/**
|
|
572
618
|
* Gets the absolute path for "pnpmfile.js" for a specific variant.
|
|
573
619
|
* @param variant - The name of the current variant in use by the active command.
|
|
@@ -603,5 +649,11 @@ export declare class RushConfiguration {
|
|
|
603
649
|
*/
|
|
604
650
|
tryGetProjectForPath(currentFolderPath: string): RushConfigurationProject | undefined;
|
|
605
651
|
private _getVariantConfigFolderPath;
|
|
652
|
+
/**
|
|
653
|
+
* Split workspace can only works on PNPM with "useWorkspaces" enabled.
|
|
654
|
+
* The workspace project can NOT depend on a split workspace project.
|
|
655
|
+
* The split workspace project CAN depend on a workspace project.
|
|
656
|
+
*/
|
|
657
|
+
private _validateSplitWorkspaceRelationships;
|
|
606
658
|
}
|
|
607
659
|
//# sourceMappingURL=RushConfiguration.d.ts.map
|
|
@@ -16,6 +16,7 @@ export interface IRushConfigurationProjectJson {
|
|
|
16
16
|
skipRushCheck?: boolean;
|
|
17
17
|
publishFolder?: string;
|
|
18
18
|
tags?: string[];
|
|
19
|
+
splitWorkspace?: boolean;
|
|
19
20
|
}
|
|
20
21
|
/**
|
|
21
22
|
* @internal
|
|
@@ -151,6 +152,11 @@ export declare class RushConfigurationProject {
|
|
|
151
152
|
* @beta
|
|
152
153
|
*/
|
|
153
154
|
readonly tags: ReadonlySet<string>;
|
|
155
|
+
/**
|
|
156
|
+
* Whether this project is a split workspace project.
|
|
157
|
+
* @beta
|
|
158
|
+
*/
|
|
159
|
+
readonly splitWorkspace: boolean;
|
|
154
160
|
/** @internal */
|
|
155
161
|
constructor(options: IRushConfigurationProjectOptions);
|
|
156
162
|
/**
|