You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
localkey=vim.keymap.setrequire("zk").setup({
picker="telescope",
lsp= {
config= {
cmd= { "zk", "lsp" },
name="zk",
on_attach=function()
key("n", "gd", function()
vim.lsp.buf.definition()
end, {})
require("cmp_nvim_lsp").default_capabilities()
end,
},
auto_attach= {
enabled=true,
filetypes= { "markdown" },
},
},
})
localcmp=require("cmp")
locallspkind=require("lspkind")
cmp.setup({
completion= {
autocomplete=false,
},
snippet= {
expand=function(args)
require("luasnip").lsp_expand(args.body)
end,
},
window= {
documentation=cmp.config.disable, -- disable docs popupcompletion=cmp.config.window.bordered(),
},
mapping=cmp.mapping.preset.insert({
["<c-k>"] =cmp.mapping.select_prev_item(),
["<c-j>"] =cmp.mapping.select_next_item(),
["<c-l>"] =cmp.mapping.complete(),
["<c-i>"] =cmp.mapping.confirm({ select=true }), -- Accept item at top of list. Set `select` to `false` to only confirm explicitly selected items.
}),
sources=cmp.config.sources({
{ name="nvim_lsp"},
{ name="luasnip"},
{ name="buffer"},
{ name="nvim_lua"},
{ name="path"},
}),
formatting= {
format=lspkind.cmp_format({
mode="symbol",
maxwidth=50,
ellipsis_char="...", -- when popup menu exceed maxwidth, the truncated part would show ellipsis_char instead (must define maxwidth first)menu= {
buffer="[buf]",
nvim_lsp="[LSP]",
luasnip="[snip]",
path="[path]",
nvim_lua="[api]",
},
}),
},
})
Environment
NVIM v0.9.4
Build type: Release
LuaJIT 2.1.1700008891
system vimrc file: "$VIM/sysinit.vim"
fall-back for$VIM: "/opt/homebrew/Cellar/neovim/0.9.4/share/nvim"
Run :checkhealth for more info
The text was updated successfully, but these errors were encountered:
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs in the next 5 days.
I can reproduce this with my neovim config as well.
This is also reproducible when 'autocomplete' is on for cmp when trying to manually trigger completion after coming from normal mode.
Like so:
In insert mode type ie. "[[AI" so that the completion lists opens up.
Enter normal mode.
Enter insert mode again.
Try to trigger autocompletion => no suggestions from zk lsp.
Check if applicable
Describe the bug
With autocomplete enabled in cmp (meaning completion will begin as soon as I start typing), lsp returns to me my notes for link creation:
However, with autocomplete set to
false
, no lsp findings are returned to me:Same goes if I type some characters and then trigger completion (i.e, no lsp results):
Furthermore, if
keyword_length
is set in nvim-cmp (which sets completion to trigger aftern
characters are typed`, it breaks the zk-nvim completion.Type [[ to trigger completion:
Type A to filter towards "AI title"
How to reproduce?
test.tar.gz
zk configuration
Neovim configuration
Environment
The text was updated successfully, but these errors were encountered: