diff options
| author | Lukas Wirth <lukastw97@gmail.com> | 2025-03-22 21:04:36 +0100 |
|---|---|---|
| committer | Lukas Wirth <lukastw97@gmail.com> | 2025-03-24 07:44:46 +0100 |
| commit | 6b9625dc0a8d5d673dbfdbeb0ad778eca062265b (patch) | |
| tree | 0273be81fc7da3f98d458bbd4d0e63652348407f /src/tools/rust-analyzer/docs | |
| parent | 2aa893313adadfad397f5899469417ba8c9e0853 (diff) | |
chore: Cleanup vscode extension output channels
Diffstat (limited to 'src/tools/rust-analyzer/docs')
| -rw-r--r-- | src/tools/rust-analyzer/docs/book/src/contributing/README.md | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/tools/rust-analyzer/docs/book/src/contributing/README.md b/src/tools/rust-analyzer/docs/book/src/contributing/README.md index 9e1cdb08893..05286b54292 100644 --- a/src/tools/rust-analyzer/docs/book/src/contributing/README.md +++ b/src/tools/rust-analyzer/docs/book/src/contributing/README.md @@ -140,9 +140,10 @@ By default, log goes to stderr, but the stderr itself is processed by VS Code. `--log-file <PATH>` CLI argument allows logging to file. Setting the `RA_LOG_FILE=<PATH>` environment variable will also log to file, it will also override `--log-file`. -To see stderr in the running VS Code instance, go to the "Output" tab of the panel and select `Rust Analyzer Client`. +To see the server stderr output in the running VS Code instance, go to the "Output" tab of the panel +and select `rust-analyzer Language Server`. This shows `eprintln!` as well. -Note that `stdout` is used for the actual protocol, so `println!` will break things. +Note that `stdout` is used by LSP messages, so using `println!`—or anything that writes to `stdout`—will break rust-analyzer! To log all communication between the server and the client, there are two choices: @@ -153,9 +154,11 @@ To log all communication between the server and the client, there are two choice ``` * You can log on the client side, by the `rust-analyzer: Toggle LSP Logs` command or enabling `"rust-analyzer.trace.server": "verbose"` workspace setting. - These logs are shown in a separate tab in the output and could be used with LSP inspector. + These logs are shown in a separate tab named `rust-analyzer LSP Trace` in the output and could be used with LSP inspector. Kudos to [@DJMcNab](https://github.com/DJMcNab) for setting this awesome infra up! +Finally there are the logs of the VSCode extension itself which go into the `rust-analyzer Extension` output tab. + There are also several VS Code commands which might be of interest: * `rust-analyzer: Status` shows some memory-usage statistics. |
