From 178c7f94bfd5789b533b4b3313ecb8e5cac0e050 Mon Sep 17 00:00:00 2001 From: osbm Date: Sun, 16 Mar 2025 00:35:30 +0300 Subject: [PATCH] add keymaps to nvim-cmp --- plugins/cmp.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/plugins/cmp.nix b/plugins/cmp.nix index 3d700a1..628823f 100644 --- a/plugins/cmp.nix +++ b/plugins/cmp.nix @@ -3,13 +3,21 @@ autoEnableSources = true; settings = { sources = [ + # LSP source { name = "nvim_lsp"; } + # For path completion { name = "path"; } + # For buffer completion { name = "buffer"; } + # For command line completion { name = "cmdline"; } ]; mapping = { + # means enter "" = "cmp.mapping.confirm({ select = true })"; + "" = "cmp.mapping.select_next_item()"; + "" = "cmp.mapping.select_prev_item()"; + "" = "cmp.mapping.close()"; }; }; };