diff options
Diffstat (limited to 'modules/home.legacy/conf/nvim/plgs/luasnip/default.nix')
-rw-r--r-- | modules/home.legacy/conf/nvim/plgs/luasnip/default.nix | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/modules/home.legacy/conf/nvim/plgs/luasnip/default.nix b/modules/home.legacy/conf/nvim/plgs/luasnip/default.nix new file mode 100644 index 00000000..130fafee --- /dev/null +++ b/modules/home.legacy/conf/nvim/plgs/luasnip/default.nix @@ -0,0 +1,20 @@ +{ + lib, + pkgs, + ... +}: { + programs.nixvim = { + plugins.luasnip = { + enable = true; + }; + extraConfigLuaPost = '' + ${lib.strings.fileContents ./lua/luasnip.lua}; + require("luasnip.loaders.from_lua").load({paths = "${./lua/snippets}"}); + require("luasnip.loaders.from_lua").lazy_load({paths = "${./lua/snippets}"}); + ''; + extraPlugins = [ + # needed for the todo-comments snippets + pkgs.vimPlugins.comment-nvim + ]; + }; +} |