Fix kakoune

This commit is contained in:
Riley Apeldoorn 2022-05-23 13:28:54 +02:00
parent 11e08fc437
commit c7110cee03
2 changed files with 17 additions and 10 deletions

View file

@ -25,13 +25,16 @@ let keybinds = ''
# Initialization code for IDE mode needed for every supported # Initialization code for IDE mode needed for every supported
# language, and inlay diagnostics. # language, and inlay diagnostics.
ide-init = '' ide-init = ''
eval %sh{ kak-lsp --kakoune -s $kak_session }
lsp-enable-window lsp-enable-window
lsp-inlay-diagnostics-enable window lsp-inlay-diagnostics-enable window
hook window ModeChange .*:.*:insert %{ remove-highlighter window/lsp_diagnostics } hook window ModeChange .*:.*:insert %{
hook window ModeChange .*:insert:normal %{ lsp-inlay-diagnostics-enable window } remove-highlighter window/lsp_diagnostics
}
hook window ModeChange .*:insert:normal %{
lsp-inlay-diagnostics-enable window
}
''; '';
# Implies `ide-init`. Adds code actions and hover. # Implies `ide-init`. Adds code actions and hover.
@ -140,9 +143,10 @@ in pkgs.writeTextFile (rec {
name = "kakrc.kak"; name = "kakrc.kak";
destination = "/share/kak/autoload/${name}"; destination = "/share/kak/autoload/${name}";
text = '' text = ''
colorscheme colors;
set global tabstop 4 set global tabstop 4
eval %sh{ kak-lsp --kakoune -s $kak_session }
add-highlighter global/ number-lines -separator ' ' -hlcursor add-highlighter global/ number-lines -separator ' ' -hlcursor
face global InlayHint rgb:828282 face global InlayHint rgb:828282
@ -159,6 +163,9 @@ in pkgs.writeTextFile (rec {
${rust-config} ${rust-config}
${nix-config} ${nix-config}
hook global KakBegin .* %{ cursorline } hook global KakBegin .* %{
cursorline
colorscheme colors
}
''; '';
}) })