Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Rust workspace dependencies instead of repeating versions in each Cargo.toml #3397

Open
teor2345 opened this issue Feb 19, 2025 · 0 comments · May be fixed by #3411
Open

Use Rust workspace dependencies instead of repeating versions in each Cargo.toml #3397

teor2345 opened this issue Feb 19, 2025 · 0 comments · May be fixed by #3411
Labels

Comments

@teor2345
Copy link
Member

Currently, when we do a large upstream upgrade (like #3394), we have to modify around 70 Cargo.toml files with the same version bumps.

But Rust supports workspace-level dependencies, where the workspace contains the version, and the crates just need to say they use the dependency (and any extra features, and if it's optional):
https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#inheriting-a-dependency-from-a-workspace

cargo-autoinherit will unify git and path dependencies automatically:
https://github.com/mainmatter/cargo-autoinherit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant