killercup / killercup/cargo-edit

Idea: run migration scripts on cargo upgrade

Open
#410 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

cargo-upgrade enhancement hard
Dominant language
Rust
Stars
3.5k
Forks
166
PR merge metrics
No merged PRs in 30d

Description

This may be out of scope of cargo-edit, but my writing this down not to forget it.
The idea is that when library authors make a breaking change, they also write a script e.g. in ra_ssr that does the migration for your code wherever possible.

Then cargo-upgrade would pull these migration scripts (assuming some convention for a standard location) and run them.
Imagine a world where even a major upgrade e.g. from tokio 0.2 to tokio 0.3 can be done with a single cargo upgrade :)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the cargo-upgrade command in cargo-edit and the proposed migration-script convention, including the ra_ssr example linked in the issue. Define the script discovery, download, execution, and safety requirements before implementation; done would mean a documented, working upgrade flow for applicable breaking dependency changes.

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
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.