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

[rush] Add installation for subspaces #4458

Merged
merged 66 commits into from
Jan 30, 2024

Conversation

william2958
Copy link
Contributor

@william2958 william2958 commented Dec 18, 2023

Summary

This MR adds the ability to install dependencies for a subspace.

Details

This MR adds the following changes:

  • Modifies where rush looks for installation and configuration files for an installation to be configurable for a specific subspace. For example, rush can now look for configuration files for a specific subspace under common/config/subspaces/first_subspace as opposed to the default common/config
  • Adds the support for the splitWorkspaceCompatibility option in the subspace configuration, which allows subspaces to specify their configuration files under the project folder itself if it is the only project in a subspace. For example, if project a is the only project in subspace first_subspace, it can have it's configuration files under the folder a/subspace/first_subspace instead of the default common/config/subspaces/first_subspace folder.
  • Allows configuration for where rush creates the /temp/ folder and all corresponding files that go under the temp folder. For example, rush can now install for a subspace under the /temp/first_subspace folder as opposed to the default /temp folder
  • Add the selector --subspace <subspace_name> for the commands rush install and rush update to install for a specific subspace.
  • Add support for filtered installs (using selectors like --to, --from, etc.) by installing all affected subspaces sequentially.
  • Add the selector for subspace tags used for building a specific workspace, e.g. rush build -o subspace:first_subspace
  • Disable checking for the link flag if subspaces are enabled (to be fix later)
  • Insert custom pnpmfile logic that links projects that are not within the same subspace.
  • Support common-versions logic within subspaces
  • Support repo-state checking within subspaces

How it was tested

Impacted documentation

Rush operation should be completely unaffected if the subspaces feature not enabled.

However since the feature is close to code complete, we're going to start work on website docs soon.

@william2958 william2958 force-pushed the will/install-subspace-cont branch from 76ac6b7 to a3d449e Compare December 21, 2023 15:15
@william2958 william2958 marked this pull request as ready for review December 21, 2023 18:44
@william2958
Copy link
Contributor Author

Note that the ignore-scripts PR features have been removed from this PR to separate the concerns. There appears to be more design decisions and reviews required the the other PR, so this PR is just to update the way rush looks for configuration files and where it installs dependencies to support subspaces.

… was subspacesFeatureEnabled passed instead of splitWorkspaceCompatibility
@octogonz octogonz merged commit 4502ce8 into microsoft:main Jan 30, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants