From af8063fe373cf06a345b0d4eee14ef1ef6873bc7 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Tue, 29 Sep 2020 22:05:18 +0200 Subject: Extend **Status** command to also show dep info for the file This should help with troubleshooting wrong project configuration --- docs/dev/lsp-extensions.md | 9 ++++++++- docs/user/manual.adoc | 4 ++-- 2 files changed, 10 insertions(+), 3 deletions(-) (limited to 'docs') diff --git a/docs/dev/lsp-extensions.md b/docs/dev/lsp-extensions.md index 2e3133449..f1160bb1c 100644 --- a/docs/dev/lsp-extensions.md +++ b/docs/dev/lsp-extensions.md @@ -390,7 +390,14 @@ rust-analyzer supports only one `kind`, `"cargo"`. The `args` for `"cargo"` look **Method:** `rust-analyzer/analyzerStatus` -**Request:** `null` +**Request:** + +```typescript +interface AnalyzerStatusParams { + /// If specified, show dependencies of the current file. + textDocument?: TextDocumentIdentifier; +} +``` **Response:** `string` diff --git a/docs/user/manual.adoc b/docs/user/manual.adoc index 7d85b36cb..c1a778852 100644 --- a/docs/user/manual.adoc +++ b/docs/user/manual.adoc @@ -113,8 +113,8 @@ Note that installing via `xtask install` does not work for VS Code Remote, inste Here are some useful self-diagnostic commands: -* **Rust Analyzer: Show RA Version** shows the version of `rust-analyzer` binary -* **Rust Analyzer: Status** prints some statistics about the server, like the few latest LSP requests +* **Rust Analyzer: Show RA Version** shows the version of `rust-analyzer` binary. +* **Rust Analyzer: Status** prints some statistics about the server, and dependency information for the current file. * To enable server-side logging, run with `env RA_LOG=info` and see `Output > Rust Analyzer Language Server` in VS Code's panel. * To log all LSP requests, add `"rust-analyzer.trace.server": "verbose"` to the settings and look for `Rust Analyzer Language Server Trace` in the panel. * To enable client-side logging, add `"rust-analyzer.trace.extension": true` to the settings and open `Output > Rust Analyzer Client` in the panel. -- cgit v1.2.3