From ceeee5e3c6e2ab24d6d83a1e000780da537c1507 Mon Sep 17 00:00:00 2001 From: rezural Date: Tue, 22 Jun 2021 07:28:33 +1000 Subject: add documentation of RA_LOG_FILE --- docs/dev/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/dev/README.md b/docs/dev/README.md index e81f1e74c..a394b8501 100644 --- a/docs/dev/README.md +++ b/docs/dev/README.md @@ -131,7 +131,8 @@ Logging is done by both rust-analyzer and VS Code, so it might be tricky to figu Inside rust-analyzer, we use the standard `log` crate for logging, and `env_logger` for logging frontend. By default, log goes to stderr, but the stderr itself is processed by VS Code. -`--log-file ` CLI argument allows logging to file. +`--log-file ` CLI argument allows logging to file. +Setting the `RA_LOG_FILE=` 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`. This shows `eprintln!` as well. -- cgit v1.2.3