mirror of
https://codeberg.org/FelipeLema/cmp-async-path
synced 2025-05-11 20:29:16 +00:00
Support chained completion
This commit is contained in:
parent
ad85ac623d
commit
b5e157c8ae
@ -107,7 +107,9 @@ source._candidates = function(_, context, dirname, offset, callback)
|
||||
if accept then
|
||||
if type == 'directory' then
|
||||
table.insert(items, {
|
||||
word = '/' .. name,
|
||||
label = '/' .. name,
|
||||
insertText = '/' .. name .. '/',
|
||||
kind = cmp.lsp.CompletionItemKind.Folder,
|
||||
})
|
||||
elseif type == 'link' then
|
||||
@ -115,7 +117,9 @@ source._candidates = function(_, context, dirname, offset, callback)
|
||||
if stat then
|
||||
if stat.type == 'directory' then
|
||||
table.insert(items, {
|
||||
word = '/' .. name,
|
||||
label = '/' .. name,
|
||||
insertText = '/' .. name .. '/',
|
||||
kind = cmp.lsp.CompletionItemKind.Folder,
|
||||
})
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user