aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src
diff options
context:
space:
mode:
authorBlaž Hrastnik2020-12-22 07:58:00 +0000
committerBlaž Hrastnik2020-12-22 07:58:00 +0000
commitc8424c6ff0bb35c7eb422578e899158e3549f85f (patch)
treed3999ff4efd7f162a687bb9d5c9b27fc19072757 /helix-term/src
parentd61b4854b8da1cd8cc9d641526dedbd0be348640 (diff)
lsp: Re-enable hooks.
Diffstat (limited to 'helix-term/src')
-rw-r--r--helix-term/src/application.rs23
1 files changed, 11 insertions, 12 deletions
diff --git a/helix-term/src/application.rs b/helix-term/src/application.rs
index dc37612a..b90ec283 100644
--- a/helix-term/src/application.rs
+++ b/helix-term/src/application.rs
@@ -83,11 +83,11 @@ impl Application {
// initialize lsp
self.language_server.initialize().await.unwrap();
- // TODO: temp
- // self.language_server
- // .text_document_did_open(&cx.editor.view().unwrap().doc)
- // .await
- // .unwrap();
+
+ self.language_server
+ .text_document_did_open(&self.editor.view().unwrap().doc)
+ .await
+ .unwrap();
self.render();
@@ -142,13 +142,12 @@ impl Application {
match notification {
Notification::PublishDiagnostics(params) => {
let path = Some(params.uri.to_file_path().unwrap());
- let view: Option<&mut helix_view::View> = None;
- // TODO:
- // let view = self
- // .editor
- // .views
- // .iter_mut()
- // .find(|view| view.doc.path == path);
+
+ let view = self
+ .editor
+ .views
+ .iter_mut()
+ .find(|view| view.doc.path == path);
if let Some(view) = view {
let doc = view.doc.text().slice(..);