about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-07-24 10:10:58 +0000
committerbors <bors@rust-lang.org>2024-07-24 10:10:58 +0000
commit5fd18ee953e426946dbb9bff4f7bd07fbbda06c3 (patch)
tree563b5eed2ebe2f93f989b521b59863353e6caaee
parent20c66980665c1424135a697a121962b15f99ccb0 (diff)
parent8c6dd09507e2bf35c83d77997f6219e757a77667 (diff)
downloadrust-5fd18ee953e426946dbb9bff4f7bd07fbbda06c3.tar.gz
rust-5fd18ee953e426946dbb9bff4f7bd07fbbda06c3.zip
Auto merge of #17674 - davidbarsky:david/add-more-information-to-status-command, r=Veykril
internal: add more output to the status command

Bit of a lazy change, but this is was pretty handy. I think I should clean up the configuration into something a bit more legible (maybe serialize as JSON?), but I think this is a good enough starting point that we might as well start asking people for it in issue reports.
-rw-r--r--src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs b/src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs
index 8ec159278d4..44ff273b5ae 100644
--- a/src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs
+++ b/src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs
@@ -111,6 +111,13 @@ pub(crate) fn handle_analyzer_status(
             .status(file_id)
             .unwrap_or_else(|_| "Analysis retrieval was cancelled".to_owned()),
     );
+
+    buf.push_str("\nVersion: \n");
+    format_to!(buf, "{}", crate::version());
+
+    buf.push_str("\nConfiguration: \n");
+    format_to!(buf, "{:?}", snap.config);
+
     Ok(buf)
 }