Autodetection of pre-existing Rust install should report full path it observed
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 7k
- Forks
- 1.1k
- Avg merge
- 22h 40m
- Merged PRs (30d)
- 46
Description
Rustup currently refuses to install Rust if it detects a pre-existing Rust install.
However, it does not tell the user which file it found the pre-existing install; it only reports the directory where it found it. E.g.:
error: it looks like you have an existing installation of Rust at:
error: /home/pnkfelix/bin
error: rustup cannot be installed alongside Rust. Please uninstall first
error: if this is what you want, restart the installation with `-y'
error: cannot install while Rust is installed
In my own case, I was able to use strace on Linux to observe the paths it was querying, and from that, make appropriate changes to my file system. (I was using symlinks in ~/bin/, and there was still a ~/bin/cargo symlink.)
However, I would not expect an average user to resort to strace to resolve this kind of problem.
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
The issue does not name a source file or test; begin at rustup's pre-existing-install detection and reproduce the installer error. Use the reported installation paths, including symlinks, to trace what is detected. Done means the error identifies the full file path that caused the existing-install check to fail.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100