Gradually warming up to the concept of a workspace.
cargo new --lib inner_crate
has got to be my new favourite thing to type.
Alas, there doesn't appear to be a simple way to add/remove an inner workspace member from the list of dependencies. Unless I'm missing something obvious? To clarify: is there a
cargo new --lib inner [--workspace/--dep]?
- to- (a) create an
inner
folder - (b) add it in
workspace.members
ofCargo.toml
- (c) add it as
inner = { path = "./inner" }
intoworkspace.dependencies
- (a) create an
cargo remove inner [--workspace/--dep]?
- to- (a) delete the same folder from the drive
- (b) remove it from
workspace.members
and.dependencies
Or anything like it built-in and shipped with cargo
?
Side question: it doesn't seem possible to have the name of the inner
in the dependencies
of the workspace itself be different from the path
and/or (?) its own package.name
- any idea why?