Manage dependencies that are shared among crates in a workspace.
Using homebrew:
brew install ecliptical/cargo-wsdeps/cargo-wsdepsUsing cargo binstall:
cargo binstall --locked cargo-wsdepsUsing cargo install:
cargo install --locked cargo-wsdepscargo wsdeps suggests three kinds of changes to a workspace:
- consolidate dependencies declared inline by 2+ member crates into shared
[workspace.dependencies]entries (and rewrite the members to useworkspace = true), - remove
[workspace.dependencies]entries that no member references, and - (with
--aggressive) move a workspace dependency back into the sole member that uses it, when only one member inherits it viaworkspace = trueand no other member references it inline.
To print a summary of suggested changes:
cargo wsdeps show [--aggressive]To generate a unified diff with the suggested changes:
cargo wsdeps diff [--dotted] [--aggressive]Copyright (c) 2025 - 2026 Ecliptical Software Inc. All rights reserved.