rust-lang / rust-lang/rustup

Toolchain override for specific cargo subcommand

Open
#762 8 comments 5 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
7k
Forks
1.1k
Avg merge
22h 40m
Merged PRs (30d)
46

Description

The idea is that you can override the toolchain used to run a specific cargo sub-command.

My use case is running cargo clippy while using the stable toolchain for everything else.
There is a workaround: rustup run nightly cargo clippy, but its pretty annoying.
With this functionality I could override the toolchain for the clippy sub-command while still using the stable toolchain for the everything else..

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 tracing how rustup selects a toolchain when invoking cargo subcommands, using the existing rustup run nightly cargo clippy workaround as the behavioral reference. Define how a toolchain override for clippy would coexist with the stable default, then verify that other cargo subcommands remain on the default toolchain.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli, tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.