diff options
Diffstat (limited to 'helix-term/src/commands')
-rw-r--r-- | helix-term/src/commands/typed.rs | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/helix-term/src/commands/typed.rs b/helix-term/src/commands/typed.rs index dfc71dfd..063658c6 100644 --- a/helix-term/src/commands/typed.rs +++ b/helix-term/src/commands/typed.rs @@ -1283,7 +1283,14 @@ fn reload( doc.reload(view, &cx.editor.diff_providers, redraw_handle) .map(|_| { view.ensure_cursor_in_view(doc, scrolloff); - }) + })?; + if let Some(path) = doc.path() { + cx.editor + .language_servers + .file_event_handler + .file_changed(path.clone()); + } + Ok(()) } fn reload_all( @@ -1324,6 +1331,12 @@ fn reload_all( let redraw_handle = cx.editor.redraw_handle.clone(); doc.reload(view, &cx.editor.diff_providers, redraw_handle)?; + if let Some(path) = doc.path() { + cx.editor + .language_servers + .file_event_handler + .file_changed(path.clone()); + } for view_id in view_ids { let view = view_mut!(cx.editor, view_id); |