1
0
mirror of https://github.com/jdhao/nvim-config.git synced 2025-06-08 14:14:33 +02:00

use nvim-cmp for cmd line completion

- remove wilder.nvim and its config
- add blink.cmp config as backup solution
This commit is contained in:
jdhao
2025-04-30 19:01:57 +02:00
parent b69dcb3a6b
commit 999a1733cf
5 changed files with 98 additions and 71 deletions

View File

@@ -7,6 +7,7 @@ require("cmp_path")
require("cmp_buffer")
require("cmp_omni")
require("cmp_nvim_ultisnips")
require("cmp_cmdline")
local MiniIcons = require("mini.icons")
@@ -71,6 +72,23 @@ cmp.setup.filetype("tex", {
},
})
cmp.setup.cmdline("/", {
mapping = cmp.mapping.preset.cmdline(),
sources = {
{ name = "buffer" },
},
})
cmp.setup.cmdline(":", {
mapping = cmp.mapping.preset.cmdline(),
sources = cmp.config.sources({
{ name = "path" },
}, {
{ name = "cmdline" },
}),
matching = { disallow_symbol_nonprefix_matching = false },
})
-- see https://github.com/hrsh7th/nvim-cmp/wiki/Menu-Appearance#how-to-add-visual-studio-code-dark-theme-colors-to-the-menu
vim.cmd([[
highlight! link CmpItemMenu Comment