From 1a21a3ce7a7bf603cd13b4c59a3049bab4855485 Mon Sep 17 00:00:00 2001 From: ozpv <39195175+ozpv@users.noreply.github.com> Date: Wed, 20 Nov 2024 15:59:03 +0000 Subject: update nixvim config --- apps/nixvim.nix | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) (limited to 'apps/nixvim.nix') diff --git a/apps/nixvim.nix b/apps/nixvim.nix index 7a959be..d2a112d 100644 --- a/apps/nixvim.nix +++ b/apps/nixvim.nix @@ -50,6 +50,12 @@ }; }; + treesitter = { + enable = true; + folding = false; + settings.indent.enable = true; + }; + lsp = { enable = true; servers = { @@ -69,6 +75,42 @@ }; }; }; + + lspkind.enable = true; + + luasnip.enable = true; + + cmp = { + enable = true; + autoEnableSources = true; + + settings = { + snippet.expand = "function(args) require('luasnip').lsp_expand(args.body) end"; + + mapping = { + "" = "cmp.mapping.confirm({ select = true })"; + "" = "cmp.mapping(cmp.mapping.select_next_item(), {'i', 's'})"; + }; + + sources = [ + {name = "path";} + {name = "nvim_lsp";} + {name = "luasnip";} + {name = "crates";} + {name = "buffer";} + ]; + }; + }; + + rustaceanvim = { + enable = false; + + settings = { + tools.enable_clippy = true; + }; + }; + + lualine.enable = true; }; colorschemes.gruvbox.enable = true; -- cgit v1.2.3