killercup / killercup/cargo-edit
Updating package rust-version to the latest version
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 3.5k
- Forks
- 166
- PR merge metrics
- No merged PRs in 30d
Description
TL;DR: Is upgrading package.rust-version within the scope of this project?
As a beginner in rust I like enabling lints to get used to idioms and avoid anti-patterns. Recently while working on a project (binary, not lib), I happened upon the use Trait as _ idiom which I decided to enforce. However the corresponding lint was only added in v1.83.
I have a function in my shell config that uses cargo-edit to upgrade all dependency crates in the current project to their latest versions. I decided to add a step to that function for upgrading the package.rust-version property to the latest stable version of rust. Looking at the help output of cargo-edit, it seemed like --rust-version was exactly what I was looking for, but looks like that's not the case:
# Update package.rust-version to latest stable version of rust
rustup update && cargo upgrade --rust-version `{rustc --version | cut -d " " -f2}` --compatible ignore # Doesn't modify cargo.toml
So I want to initiate a discussion on whether that's something this project would consider supporting.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the cargo upgrade --rust-version help output and the reported command behavior in cargo-edit. No implementation file or test is named in the issue, so first determine where package.rust-version handling belongs. Done would require a project decision on whether this capability is supported and a defined behavior if it is.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100