Build only the default run binary #9491
Labels
C-feature-request
Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`
Command-run
I'd like a way to build only the default run binary, i.e. what
cargo run
runs. (I'm writing a subcommand that lets the user run the various binaries cargo builds under a time-travelling debugger. By default, I want to build and run only the default run binary)Describe the solution you'd like
Either
cargo build --default-bin
, or some way to get the name of the default binary.(I think
--no-run
is being phased out. If not,cargo run --no-run
could also be added, although it sounds a little silly.)Notes
If this is a wontfix I'd like to confirm that the algorithm used by cargo run is as follows.
cargo metadata
#9497 to get fromcargo metadata
)The text was updated successfully, but these errors were encountered: