Use rust-analyzer from path if possible (#12418)

Release Notes:

- Added support for looking up the `rust-analyzer` binary in `$PATH`. This allows using such tools as `asdf` and nix to configure per-folder rust installations. To enable this behavior, use the `path_lookup` key when configuring the `rust-analyzer` `binary`: `{"lsp": {"rust-analyzer": {"binary": {"path_lookup": true }}}}`.
This commit is contained in:
Stanislav Alekseev 2024-06-07 07:56:38 +03:00 committed by GitHub
parent 48581167b7
commit 07dbd2bce8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 83 additions and 51 deletions

View file

@ -94,6 +94,7 @@ const fn true_value() -> bool {
pub struct BinarySettings {
pub path: Option<String>,
pub arguments: Option<Vec<String>>,
pub path_lookup: Option<bool>,
}
#[derive(Clone, Debug, Default, Serialize, Deserialize, PartialEq, Eq, JsonSchema)]