It is a question / proposal / discussion. I am looking for alternatives to initialize (install / make available) tools required for a development and management of a rust project, without actually installing them manually
Let’s say there is a Rust source code based project in a repository. As any other Rust based project, it would require rustup and cargo binaries available on the development machine. These are expected to be installed by every rust developer.
Next this project opts into using various 3rd party tools, which are installed by
cargo install. Examples of this could be
cargo-make, etc… Next the project can have automated aliases to invoke typical commands, like it is described here.
As a result we have got a project, which supports natively via cargo or via 3rd party tools, workflows like:
cargo build cargo test cargo check-updates cargo release cargo review cargo approve # and so on, depending on what a project might require to have
Now the problem is: when a fresh clone (or pull) of a project is done with newly required dependencies to 3rd party tools, it is expected that all developers stay in sync and install these tools manually. And here could be variations with versions being installed and so on.
Ideally, I would like the project to declare dependencies to the required tools and versions, like NPM does. It requires dependencies declared in
dev dependencies section of
package.json and requires running
npm install to keep things in sync after clone or pull.
I understand this is not currently possible with cargo and cargo.toml.? However, if it was possible, I would not like to run
cargo install (analogy of
npm install) after every clone or pull. I would prefer cargo to figure out what and if tools need to be installed based on tool dependencies declaration, current state of my system / workspace / project and command being invoked.
So, what are the options available? Where is rust heading in relation to this?