diff --git a/nvim/lua/plugins/lsp/cmp.lua b/nvim/lua/plugins/lsp/cmp.lua index cc8c76a..481d3e1 100755 --- a/nvim/lua/plugins/lsp/cmp.lua +++ b/nvim/lua/plugins/lsp/cmp.lua @@ -56,12 +56,10 @@ return { [""] = cmp.mapping(function(fallback) if cmp.visible() then cmp.confirm({ behavior = cmp.ConfirmBehavior.Insert, select = true }) - elseif require("luasnip").expandable() then - -- Expands snippet if possible - require("luasnip").expand() else -- Otherwise, fallback (insert a tab character) - fallback() + require("neotab").tabout() + -- fallback() end end, { "i", "s" }), diff --git a/nvim/lua/plugins/util/neotab.lua b/nvim/lua/plugins/util/neotab.lua new file mode 100644 index 0000000..e35c404 --- /dev/null +++ b/nvim/lua/plugins/util/neotab.lua @@ -0,0 +1,7 @@ +return { + "kawre/neotab.nvim", + event = "InsertEnter", + opts = { + tabkey = "", + }, +}