Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Show Copilot logs right after its LSP server start
Kirill Bulatov6ebe49ec591c
diff --git a/crates/copilot/src/copilot.rs b/crates/copilot/src/copilot.rsindex 29b92ec3619..4b81bebc02e 100644--- a/crates/copilot/src/copilot.rs+++ b/crates/copilot/src/copilot.rs@@ -277,7 +277,7 @@ pub struct Copilot {}pub enum Event {- CopilotReady,+ CopilotLanguageServerStarted,}impl Entity for Copilot {@@ -431,6 +431,7 @@ impl Copilot {sign_in_status: SignInStatus::SignedOut,registered_buffers: Default::default(),});+ cx.emit(Event::CopilotLanguageServerStarted);this.update_sign_in_status(status, cx);}Err(error) => {@@ -873,7 +874,6 @@ impl Copilot {self.register_buffer(&buffer, cx);}}- cx.emit(Event::CopilotReady);}request::SignInStatus::NotAuthorized { .. } => {server.sign_in_status = SignInStatus::Unauthorized;diff --git a/crates/project/src/project.rs b/crates/project/src/project.rsindex 42f26a65410..7b6aba72c4c 100644--- a/crates/project/src/project.rs+++ b/crates/project/src/project.rs@@ -8038,7 +8038,7 @@ fn subscribe_for_copilot_events(cx.subscribe(copilot,|project, copilot, copilot_event, cx| match copilot_event {- copilot::Event::CopilotReady => {+ copilot::Event::CopilotLanguageServerStarted => {if let Some((name, copilot_server)) = copilot.read(cx).language_server() {let new_server_id = copilot_server.server_id();if let hash_map::Entry::Vacant(v) =