From 7d6c4142b2cb587a8a1ceebe667ce27580d7dc7b Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Tue, 27 Jul 2021 19:40:19 +0300 Subject: [PATCH] fix: add capability for "open cargo.toml" lsp extension --- crates/rust-analyzer/src/caps.rs | 1 + docs/dev/lsp-extensions.md | 2 ++ 2 files changed, 3 insertions(+) diff --git a/crates/rust-analyzer/src/caps.rs b/crates/rust-analyzer/src/caps.rs index ddee475040..17d0ed1b65 100644 --- a/crates/rust-analyzer/src/caps.rs +++ b/crates/rust-analyzer/src/caps.rs @@ -114,6 +114,7 @@ pub fn server_capabilities(config: &Config) -> ServerCapabilities { moniker_provider: None, experimental: Some(json!({ "joinLines": true, + "openCargoToml": true, "ssr": true, "onEnter": true, "parentModule": true, diff --git a/docs/dev/lsp-extensions.md b/docs/dev/lsp-extensions.md index 78e14b01e4..5d98c0f099 100644 --- a/docs/dev/lsp-extensions.md +++ b/docs/dev/lsp-extensions.md @@ -619,6 +619,8 @@ Such actions on the client side are appended to a hover bottom as command links: **Issue:** https://github.com/rust-analyzer/rust-analyzer/issues/6462 +**Experimental Server Capability:** `{ "openCargoToml": boolean }` + This request is sent from client to server to open the current project's Cargo.toml **Method:** `experimental/openCargoToml`