diff options
| author | seth <[email protected]> | 2024-04-09 19:49:37 -0400 |
|---|---|---|
| committer | seth <[email protected]> | 2024-04-09 19:49:37 -0400 |
| commit | 16a1126200932407f9f4562fba961b514a1c91d1 (patch) | |
| tree | 3ab1b6f1035436a644465757c38c17d7943cea11 /config/plugins/cmp.lua | |
| parent | 43dbb8549d0ecc6dd62a5fd5f9b63beacbfc487b (diff) | |
auto import all files, cleanup + add a few things
Diffstat (limited to 'config/plugins/cmp.lua')
| -rw-r--r-- | config/plugins/cmp.lua | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/config/plugins/cmp.lua b/config/plugins/cmp.lua deleted file mode 100644 index eee5eb1..0000000 --- a/config/plugins/cmp.lua +++ /dev/null @@ -1,42 +0,0 @@ -local cmp = require("cmp") - -cmp.setup({ - completion = { - compleopt = "menu,menuone,insert", - }, - - snippet = { - expand = function(args) - require("luasnip").lsp_expand(args.body) - end, - }, - - mapping = { - ["<C-n>"] = cmp.mapping.select_next_item({ behavior = cmp.SelectBehavior.Insert }), - ["<C-p>"] = cmp.mapping.select_prev_item({ behavior = cmp.SelectBehavior.Insert }), - ["<C-b>"] = cmp.mapping.scroll_docs(-4), - ["<C-f>"] = cmp.mapping.scroll_docs(4), - ["<C-Space>"] = cmp.mapping.complete(), - ["<C-e>"] = cmp.mapping.abort(), - ["<CR>"] = cmp.mapping({ - i = function(fallback) - if cmp.visible() and cmp.get_active_entry() then - cmp.confirm({ behavior = cmp.ConfirmBehavior.Replace, select = false }) - else - fallback() - end - end, - - s = cmp.mapping.confirm({ select = true }), - c = cmp.mapping.confirm({ behavior = cmp.ConfirmBehavior.Replace, select = true }), - }), - }, - - sources = cmp.config.sources({ - { name = "nvim_lsp" }, - { name = "luasnip" }, - { name = "async_path" }, - { name = "buffer" }, - { name = "rg" }, - }), -}) |
