Skip to content

vCard source for completion-nvim, nvim-compe and nvim-cmp

License

Notifications You must be signed in to change notification settings

cbarrete/completion-vcard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 

Repository files navigation

completion-vcard

vCard completion source for native Neovim LSP autocompletion (see :h lsp-autocompletion), nvim-cmp, nvim-compe, and completion-nvim.

Usage

Native autocompletion

Add the following to after/ftplugin/mail.lua:

require('completion_vcard').setup_native('~/path/to/vcard/dir')

This will start an LSP client attached to a fake in-process LSP server that only support completion requests.

nvim-cmp

require('cmp').setup({
    -- ...
    sources = {
        { name = 'vCard' },
        -- ...
    },
})

require('cmp').register_source('vCard', require('completion_vcard').setup_cmp('~/path/to/vcard/dir'))

nvim-compe

require('completion_vcard').setup_compe('~/path/to/vcard/dir')

require('compe').setup({
    source = {
        vCard = true,
        -- probably some other sources as well
    }
})

completion-nvim

require('completion_vcard').setup_completion('~/path/to/vcard/dir')

vim.g.completion_chain_complete_list = {
    { complete_items = { 'lsp', 'vCard' }},
    { mode = '<c-n>' }
}

About

vCard source for completion-nvim, nvim-compe and nvim-cmp

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages