From 7ec1fa7385c1b88a2efdad72c805b254c52084bd Mon Sep 17 00:00:00 2001 From: A Farzat Date: Wed, 6 Nov 2024 09:09:37 +0900 Subject: Remove nvim submodule Nvim config will be included as bare files instead of a submodule. The nvim config repo will still exist, but the content will be used by yadm without the repo itself. --- .config/nvim/plugin-settings/luasnip.lua | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .config/nvim/plugin-settings/luasnip.lua (limited to '.config/nvim/plugin-settings/luasnip.lua') diff --git a/.config/nvim/plugin-settings/luasnip.lua b/.config/nvim/plugin-settings/luasnip.lua new file mode 100644 index 0000000..c8cd578 --- /dev/null +++ b/.config/nvim/plugin-settings/luasnip.lua @@ -0,0 +1,32 @@ +local luasnip = require("luasnip") + +require("luasnip.loaders.from_vscode").lazy_load() + +local opts = { noremap = true, silent = true } + +vim.keymap.set("i", "", function() + luasnip.expand() +end, opts) +vim.keymap.set("s", "", function() + luasnip.expand() +end, opts) +vim.keymap.set("i", "", function() + if luasnip.jumpable(1) then + luasnip.jump(1) + end +end, opts) +vim.keymap.set("s", "", function() + if luasnip.jumpable(1) then + luasnip.jump(1) + end +end, opts) +vim.keymap.set("i", "", function() + if luasnip.jumpable(-1) then + luasnip.jump(-1) + end +end, opts) +vim.keymap.set("s", "", function() + if luasnip.jumpable(-1) then + luasnip.jump(-1) + end +end, opts) -- cgit v1.2.3-70-g09d2