From 8269bcec3cd50632ee2539a98b12fbc122e9406d Mon Sep 17 00:00:00 2001
From: listout <listout@protonmail.com>
Date: Fri, 17 Feb 2023 11:59:47 +0530
Subject: nvim: lua: cmp: correct git souce for nvim-cmp

Signed-off-by: listout <listout@protonmail.com>
---
 lua/plugins/cmp.lua | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

(limited to 'lua')

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 },
-- 
cgit v1.2.3