Add language format and code action edits
This commit is contained in:
+9
-1
@@ -30,6 +30,10 @@ pub const Action = union(enum) {
|
||||
hover,
|
||||
signature,
|
||||
expand_hover,
|
||||
language_format,
|
||||
language_format_policy,
|
||||
language_organize_imports,
|
||||
language_code_actions,
|
||||
diagnostics_open,
|
||||
diagnostics_next,
|
||||
diagnostics_previous,
|
||||
@@ -220,7 +224,11 @@ pub const Leader = struct {
|
||||
self.mode = .idle;
|
||||
if (std.mem.eql(u8, text, "h")) return .hover;
|
||||
if (std.mem.eql(u8, text, "s")) return .signature;
|
||||
if (std.mem.eql(u8, text, "o")) return .expand_hover;
|
||||
if (std.mem.eql(u8, text, "o")) return .language_organize_imports;
|
||||
if (std.mem.eql(u8, text, "f")) return .language_format;
|
||||
if (std.mem.eql(u8, text, "F")) return .language_format_policy;
|
||||
if (std.mem.eql(u8, text, "w")) return .language_format_policy;
|
||||
if (std.mem.eql(u8, text, "a")) return .language_code_actions;
|
||||
self.message = "language action is not built in this profile yet";
|
||||
return .{ .not_built = .lsp };
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user