Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Show toolchain paths in rustup show -v output#4270

Merged
rami3l merged 1 commit into
rust-lang:masterfrom
CLoaKY233:show-toolchain-paths
Mar 30, 2025
Merged

Show toolchain paths in rustup show -v output#4270
rami3l merged 1 commit into
rust-lang:masterfrom
CLoaKY233:show-toolchain-paths

Conversation

@CLoaKY233
Copy link
Copy Markdown
Contributor

This PR implements the feature requested in issue #3408 by adding path information for each installed toolchain when using the -v verbose flag with rustup show.

Changes

  1. Modified the show function in src/cli/rustup_mode.rs to display the path for each installed toolchain in verbose mode
  2. Now all toolchains show their paths in the detailed output, not just the active toolchain

Before

installed toolchains
--------------------
stable-x86_64-pc-windows-msvc (active, default)
  rustc 1.85.1 (4eb161250 2025-03-15)

1.81-x86_64-pc-windows-msvc
  rustc 1.81.0 (eeb90cda1 2024-09-04)

After

installed toolchains
--------------------
stable-x86_64-pc-windows-msvc (active, default)
  rustc 1.85.1 (4eb161250 2025-03-15)
  path: C:\Users\laysh\.rustup\toolchains\stable-x86_64-pc-windows-msvc

1.81-x86_64-pc-windows-msvc
  rustc 1.81.0 (eeb90cda1 2024-09-04)
  path: C:\Users\laysh\.rustup\toolchains\1.81-x86_64-pc-windows-msvc

Fixes #3408

@CLoaKY233 CLoaKY233 marked this pull request as draft March 29, 2025 06:51
@CLoaKY233 CLoaKY233 marked this pull request as ready for review March 29, 2025 08:17
Comment thread src/cli/rustup_mode.rs
Copy link
Copy Markdown
Member

@rami3l rami3l left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for the contribution!

Before merging this PR, could you please squash these changes into one commit? Many thanks in advance 🙏

@CLoaKY233 CLoaKY233 marked this pull request as draft March 29, 2025 14:17
@CLoaKY233 CLoaKY233 force-pushed the show-toolchain-paths branch from d522731 to 04d095c Compare March 29, 2025 15:14
@CLoaKY233 CLoaKY233 force-pushed the show-toolchain-paths branch from 04d095c to d2c650e Compare March 29, 2025 15:17
@CLoaKY233 CLoaKY233 marked this pull request as ready for review March 29, 2025 15:29
@CLoaKY233
Copy link
Copy Markdown
Contributor Author

CLoaKY233 commented Mar 29, 2025

@rami3l changes made, and commits squashed, any changes you suggest?

Copy link
Copy Markdown
Contributor

@djc djc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me, thanks!

@rami3l
Copy link
Copy Markdown
Member

rami3l commented Mar 30, 2025

@CLoaKY233 Thanks for your contribution, and LGTM!

@rami3l rami3l added this pull request to the merge queue Mar 30, 2025
Merged via the queue into rust-lang:master with commit c89f131 Mar 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

rustup show should include toolchain link paths (maybe only with show -v)

3 participants