-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of #10517 - Muscraft:rfc2906-part2, r=epage
Part 2 of RFC2906 -- allow inheriting from a different `Cargo.toml` Tracking issue: #8415 RFC: rust-lang/rfcs#2906 [Part 1](#10497) This PR focuses on inheriting from a root workspace: - Allow inheriting from a different `Cargo.toml` - Add in searching for a workspace root in `to_real_manifest` as needed - Fixed problem where a package would try to pull a dependency from a workspace and specify `{ workspace = true, optional = true }` and it would not respect the `optional` - Added tests to verify everything is in working order Remaining implementation work for the RFC - Correctly inherit fields that are relative paths - Including adding support for inheriting `license_file`, `readme`, and path-dependencies - Path dependencies infer version directive - Lock workspace dependencies and warn when unused - Optimizations, as needed - Evaluate any new fields for being inheritable (e.g. `rust-version`) Problems: - There is duplication of code that can't be removed without significant refactoring - Potential to parse the same manifest many times when searching for a root - This should not happen when a `[package]` specifies its workspace - This should only happen if the workspace root is greater than one folder above
- Loading branch information
Showing
5 changed files
with
760 additions
and
106 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.