mirror of
https://github.com/rust-lang/cargo.git
synced 2025-09-28 11:20:36 +00:00
Added workspace_default_members.
This commit is contained in:
parent
9984c88ea8
commit
8c96a28ff7
@ -43,6 +43,7 @@ pub fn output_metadata(ws: &Workspace<'_>, opt: &OutputMetadataOptions) -> Cargo
|
||||
Ok(ExportInfo {
|
||||
packages,
|
||||
workspace_members: ws.members().map(|pkg| pkg.package_id()).collect(),
|
||||
workspace_default_members: ws.default_members().map(|pkg| pkg.package_id()).collect(),
|
||||
resolve,
|
||||
target_directory: ws.target_dir().into_path_unlocked(),
|
||||
version: VERSION,
|
||||
@ -58,6 +59,7 @@ pub fn output_metadata(ws: &Workspace<'_>, opt: &OutputMetadataOptions) -> Cargo
|
||||
pub struct ExportInfo {
|
||||
packages: Vec<SerializedPackage>,
|
||||
workspace_members: Vec<PackageId>,
|
||||
workspace_default_members: Vec<PackageId>,
|
||||
resolve: Option<MetadataResolve>,
|
||||
target_directory: PathBuf,
|
||||
version: u32,
|
||||
|
@ -65,6 +65,7 @@ fn cargo_metadata_simple() {
|
||||
}
|
||||
],
|
||||
"workspace_members": ["foo 0.5.0 (path+file:[..]foo)"],
|
||||
"workspace_default_members": ["foo 0.5.0 (path+file:[..]foo)"],
|
||||
"resolve": {
|
||||
"nodes": [
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user