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

Fix rush add -p affecting all subspace projects #4658

Merged
merged 4 commits into from
Apr 17, 2024

Conversation

william2958
Copy link
Contributor

Summary

Currently running rush add -p <package_name> results in every project being updated in a subspace. This fixes the issue.

Details

How it was tested

Impacted documentation

@octogonz octogonz merged commit 9799893 into microsoft:main Apr 17, 2024
5 checks passed
@@ -325,6 +325,7 @@ export class PackageJsonUpdater {
this._rushConfiguration
);

// console.log('adding project, updating projects: ', projects);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this line?

@@ -342,10 +343,12 @@ export class PackageJsonUpdater {
dependencyAnalyzer: DependencyAnalyzer,
options: IPackageJsonUpdaterRushAddOptions
): Promise<IUpdateProjectOptions[]> {
const { packagesToUpdate, devDependency, peerDependency, updateOtherPackages } = options;
const { projects, packagesToUpdate, devDependency, peerDependency, updateOtherPackages } = options;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be more intuitive to design the API as _updateProjects(projects, dependencyAnalyzer, { subspace, ... })?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Never mind. It's a private function.

@joelrbrandt
Copy link
Contributor

Thanks @william2958 , @octogonz , and all for a quick fix, and for your continued dedication to this project!

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.

None yet

4 participants