`rustup self uninstall --no-modify-path` is leaving dangling source line in rc files
Los mantenedores suelen responder en 1 día
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 58/100
Línea de trabajo
Start by tracing the Unix uninstall path for rustup self uninstall --no-modify-path and how it handles the CARGO_HOME/env script and shell rc entries. Reproduce the reported warning after uninstalling with that option, then check whether keeping the env script resolves it without changing default uninstall behavior. Done means the rc file no longer sources a missing script.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Verification
- I searched for recent similar issues at https://github.com/rust-lang/rustup/issues?q=is%3Aissue and found no duplicates.
- I am on the latest version of Rustup according to https://github.com/rust-lang/rustup/tags and am still able to reproduce my issue.
Problem
Due to our current uninstallation policy, by default, we're adding a line in user's rc file for sourcing a env script implement the auto PATH adding upon normal installation with modify path.
However, the current uninstallatio by default removes all of the files in CARGO_HOME and RUSTUP_HOME, causing uninstallation with rustup self uninstall --no-modify-path leaving behind a source cmd for sourcing nothing.
Steps
- Install rustup with modify path on any Unix os.
- Uninstall rustup with
rustup self uninstall --no-modify-path.
If you're using bash/zsh/ash, this would immediately causing a warn like this:
source:xxx: no such file or directory: cargo_home/env
Possible Solution(s)
Keep the env script upon rustup self uninstall --no-modify-path.
Notes
No response
Rustup version
rustup 1.29.3 (2026-11-11)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: the currently active `rustc` version is `rustc 1.100.0 (0ef1bc386 2026-11-09)`
Installed toolchains
Not related.
OS version
Any Unix OS.
- Lenguaje dominante
- Rust
- Estrellas
- 7.1k
- Forks
- 1.1k
- Merge medio
- 16 h 36 min
- PR fusionados (30 d)
- 54
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de rust-lang/rustup
-
Upgrade Windows SDK to 28000Abiertoenhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
Los mantenedores suelen responder en 1 día
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
rust-lang/rustup#5172 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
enhancement O-shell
Dificultad 1/5 Menos de una hora Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día
-
RustUp-init and better arm64 support for Windows.Posiblemente ocupada @crutkas la tomó hace 1 día. Abiertoenhancement
Dificultad 3/5 1-2 días Aptitud para principiantes 66/100
Los mantenedores suelen responder en 1 día
Todos los issues de rust-lang/rustup
Issues similares
-
bug P2
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
Los mantenedores suelen responder en 1 día
-
bug core-lang
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día
-
Windows microphone listing treats words in a device name as DirectShow labelsPosiblemente ocupada @Sujal-chaudhary la tomó hoy. Abiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
clipy-recorder/clipy#447 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
nightly-cleanup
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
max-sixty/worktrunk#4939 · 1 reacción ·
Los mantenedores suelen responder en 1 día