@@ -59,7 +59,7 @@ impl<'a> Prepare<'a> {
59
59
}
60
60
61
61
let res = Command :: new ( self . workspace , self . toolchain . cargo ( ) )
62
- . args ( & [ "read-manifest " , "--manifest-path" , "Cargo.toml" ] )
62
+ . args ( & [ "metadata " , "--manifest-path" , "Cargo.toml" , "--no-deps "] )
63
63
. cd ( self . source_dir )
64
64
. log_output ( false )
65
65
. run ( ) ;
@@ -196,7 +196,7 @@ impl<'a> TomlTweaker<'a> {
196
196
197
197
self . remove_missing_items ( "example" ) ;
198
198
self . remove_missing_items ( "test" ) ;
199
- self . remove_workspaces ( ) ;
199
+ self . remove_parent_workspaces ( ) ;
200
200
self . remove_unwanted_cargo_features ( ) ;
201
201
self . remove_dependencies ( ) ;
202
202
self . apply_patches ( ) ;
@@ -237,13 +237,9 @@ impl<'a> TomlTweaker<'a> {
237
237
}
238
238
}
239
239
240
- fn remove_workspaces ( & mut self ) {
240
+ fn remove_parent_workspaces ( & mut self ) {
241
241
let krate = self . krate . to_string ( ) ;
242
242
243
- if self . table . remove ( "workspace" ) . is_some ( ) {
244
- info ! ( "removed workspace from {}" , krate) ;
245
- }
246
-
247
243
// Eliminate parent workspaces
248
244
if let Some ( & mut Value :: Table ( ref mut package) ) = self . table . get_mut ( "package" ) {
249
245
if package. remove ( "workspace" ) . is_some ( ) {
@@ -467,6 +463,9 @@ mod tests {
467
463
468
464
[ target. "cfg(unix)" . dependencies]
469
465
quux = { version = "1.0" }
466
+
467
+ [ workspace]
468
+ members = [ ]
470
469
} ;
471
470
472
471
let krate = Crate :: local ( "/dev/null" . as_ref ( ) ) ;
0 commit comments