Closed
Description
The VS Code configuration rust-analyzer.server.path
exists to use a local binary, which is great when testing stuff, and also when using from a dev container. However, it expects a full path, which doesn't work well with version-controlled binaries. For example, if I set it to:
The extension will fail, printing the following error to Rust Analyzer Client
VS Code output channel:
INFO [1/12/2023, 7:10:00 PM]: Starting language client
INFO [1/12/2023, 7:10:00 PM]: Using server binary at bin/rust-analyzer
ERROR [1/12/2023, 7:10:00 PM]: Bootstrap error Error: Failed to execute bin/rust-analyzer --version. `config.server.path` or `config.serverPath` has been set explicitly. Consider removing this config or making a valid server binary available at that path.
I wanted to propose executing that command relative to the workspace directory, to allow users to specify paths that are relative to the repository they are working on, instead of forcing them to use machine-wide installations.