#cargo-version #version #cargo-manifest #cargo #docker #manifest #cache

app strip_cargo_version

Strip the version information from the Cargo manifests of your crates

3 releases

0.0.3 Jul 7, 2021
0.0.2 Jul 7, 2021
0.0.1 Jul 7, 2021

#24 in #cargo-manifest

MPL-2.0 license

9KB
100 lines

strip_cargo_version

A small hacky utility for setting the version of a Rust crate to 0.0.0.

I use this for optimising build-times in Docker, avoiding having to recompile dependencies when bumping the crate version.

It currently works by simply setting package.version in Cargo.toml, as well as setting package.<name>.version in Cargo.lock (where <name> is the package.name value in Cargo.toml).

If the Cargo.toml contains a workspace, it will strip workspace.members as well.

Dependencies

~2.5MB
~43K SLoC