feat: migrate LSP to opt-in native language servers
This commit is contained in:
+24
-2
@@ -896,8 +896,20 @@ impl Editor {
|
||||
name: "core".into(),
|
||||
required_capabilities: Vec::new(),
|
||||
commands: [
|
||||
"w", "q", "q!", "wq", "plugins", "edit", "buffers", "buffer", "bnext",
|
||||
"bprev", "bdelete", "bdelete!",
|
||||
"w",
|
||||
"q",
|
||||
"q!",
|
||||
"wq",
|
||||
"plugins",
|
||||
"edit",
|
||||
"buffers",
|
||||
"buffer",
|
||||
"bnext",
|
||||
"bprev",
|
||||
"bdelete",
|
||||
"bdelete!",
|
||||
"lsp_definition",
|
||||
"lsp_diagnostics",
|
||||
]
|
||||
.into_iter()
|
||||
.map(str::to_owned)
|
||||
@@ -2384,6 +2396,16 @@ impl Editor {
|
||||
});
|
||||
}
|
||||
match name {
|
||||
"lsp_definition" | "lsp_diagnostics" if !args.is_empty() => {
|
||||
self.set_message(format!("The {name} command takes no arguments"));
|
||||
}
|
||||
"lsp_definition" | "lsp_diagnostics" => {
|
||||
return Some(Invocation {
|
||||
plugin: "core".into(),
|
||||
command: name.into(),
|
||||
args: String::new(),
|
||||
});
|
||||
}
|
||||
"w" | "wq" => {
|
||||
if self.save(if args.is_empty() {
|
||||
None
|
||||
|
||||
Reference in New Issue
Block a user