summaryrefslogtreecommitdiff
path: root/lua/plugins
diff options
context:
space:
mode:
authorlistout <listout@protonmail.com>2022-10-24 00:06:41 +0530
committerlistout <listout@protonmail.com>2022-10-24 00:06:41 +0530
commitae49f604eb0b35f2b10e4dc592d6ec1979457f8f (patch)
tree6374ac5d52c1a234f9b955bb4519078263856f84 /lua/plugins
parente1ba0434ec95064f285e4838977887922b8b043e (diff)
main: cmp.lua: add omni symbol in formatting and completion under formatting
Signed-off-by: listout <listout@protonmail.com>
Diffstat (limited to 'lua/plugins')
-rw-r--r--lua/plugins/cmp.lua8
1 files changed, 7 insertions, 1 deletions
diff --git a/lua/plugins/cmp.lua b/lua/plugins/cmp.lua
index 2f901c1..e32387e 100644
--- a/lua/plugins/cmp.lua
+++ b/lua/plugins/cmp.lua
@@ -51,10 +51,15 @@ cmp.setup {
luasnip = "[LuaSnip]",
nvim_lua = "[Lua]",
latex_symbols = "[LaTeX]",
+ omni = "[Omni]",
})[entry.source.name]
return vim_item
end
},
+ completion = {
+ keyword_length = 1,
+ completeopt = "menu,noselect"
+ },
snippet = {
expand = function(args)
require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
@@ -94,8 +99,9 @@ cmp.setup {
end, { 'i', 's' }),
}),
sources = cmp.config.sources({
+ { name = 'omni'},
{ name = 'luasnip', option = { use_show_condition = false } },
- { name = 'nvim_lsp' },
+ { name = 'nvim_lsp', },
{ name = 'nvim_lsp_signature_help' },
{ name = 'path' },
{ name = 'buffer' },