From e284c4889ce27f99f37096cb838ac51bf9f48a0f Mon Sep 17 00:00:00 2001 From: Malte Tammena Date: Thu, 18 Aug 2022 14:25:42 +0200 Subject: [PATCH] [user/malte] Adjust kakoune settings --- users/malte/kakoune.nix | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/users/malte/kakoune.nix b/users/malte/kakoune.nix index ba63f80..80eb599 100644 --- a/users/malte/kakoune.nix +++ b/users/malte/kakoune.nix @@ -90,6 +90,13 @@ key = "l"; effect = ":enter-user-mode lsp"; } + { + # Next placeholder in template + docstring = "Select next snippet placeholder"; + mode = "insert"; + key = ""; + effect = ":try lsp-snippets-select-next-placeholders catch %{ execute-keys -with-hooks tab> }"; + } ]; hooks = [ { @@ -104,13 +111,6 @@ # === Additional mappings for kakoune === additionalMappings = [ - { - # Switch to last buffer - docstring = "Previous buffer"; - mode = "user"; - key = ","; - effect = ":buffer-previous"; - } { # Toggle whitespace highlighter docstring = "Toggle whitespace"; @@ -169,12 +169,6 @@ kakLspConfigGen = pkgs.formats.toml {}; kakLspConfig = { language = { - javascript = { - args = ["lsp"]; - command = "${pkgs.flow}/bin/flow"; - filetypes = ["javascript"]; - roots = [".flowconfig"]; - }; latex = { command = "${pkgs.texlab}/bin/texlab"; filetypes = ["latex"]; @@ -231,9 +225,9 @@ settings_section = "rust-analyzer"; }; typescript = { - args = ["--stdio" "--tsserver-path=${pkgs.nodePackages.typescript}/lib/node_modules/typescript/lib"]; command = "${pkgs.nodePackages.typescript-language-server}/bin/typescript-language-server"; - filetypes = ["typescript"]; + args = ["--stdio" "--tsserver-path=${pkgs.nodePackages.typescript}/lib/node_modules/typescript/lib"]; + filetypes = ["typescript" "javascript"]; roots = ["package.json" "tsconfig.json" ".git" ".hg"]; }; vuejs = {