Open
Description
It's often useful to run custom subcommands for another target, such as asm
, deb
, or others. Since we can't necessarily enumerate every subcommand, there's a few solutions I see:
- Create an environment variable, forcing the command to run in the image, such as
CROSS_FORCE_RUN_IN_IMAGE=1
. This name isn't ideal, so we'd probably modify it to something else. - If pre-build hooks are a thing and we're fine not supporting custom images, we could write a config file (just a TOML list of known extra subcommands) and parse this if the subcommand isn't known.
- Get the output of
cross --list
if the subcommand isn't known, parse it, and if the subcommand is known, run it in the image.
We need to support the following, at the very least:
- cargo-valgrind
- cargo-asm
- cargo-deb
- cargo-auditable
- cargo-bloat