summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlistout <listout@protonmail.com>2023-02-17 11:59:47 +0530
committerlistout <listout@protonmail.com>2023-02-17 11:59:47 +0530
commit8269bcec3cd50632ee2539a98b12fbc122e9406d (patch)
tree916e2e67deec7e402f0892e9c7035155cf9d86d7
parentd2fdecf5ab37b2f2b9ec5456d9c0fc80f075ca70 (diff)
nvim: lua: cmp: correct git souce for nvim-cmp
Signed-off-by: listout <listout@protonmail.com>
-rw-r--r--lua/plugins/cmp.lua8
1 files changed, 5 insertions, 3 deletions
diff --git a/lua/plugins/cmp.lua b/lua/plugins/cmp.lua
index 25bce4b..9a2c3dd 100644
--- a/lua/plugins/cmp.lua
+++ b/lua/plugins/cmp.lua
@@ -105,11 +105,12 @@ cmp.setup {
-- Set configuration for specific filetype.
cmp.setup.filetype('gitcommit', {
sources = cmp.config.sources({
- { name = 'cmp_git' }, -- You can specify the `cmp_git` source if you were installed it.
- }, {
+ { name = 'git' }, -- You can specify the `cmp_git` source if you were installed it.
{ name = 'buffer' },
- })
+ }),
+ require("cmp_git").setup(),
})
+
-- Use buffer source for `/` (if you enabled `native_menu`, this won't work anymore).
require'cmp'.setup.cmdline('/', {
completion = { autocomplete = false },
@@ -118,6 +119,7 @@ require'cmp'.setup.cmdline('/', {
{ name = 'buffer', opts = { keyword_pattern = [=[[^[:blank:]].*]=] } }
}
})
+
-- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore).
cmp.setup.cmdline(':', {
completion = { autocomplete = false },