Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

completions appearing only after sourcing vimrc twice #14

Open
@dhananjayraut

Description

when using this plugin as a completion source completions do not appear as soon as I open a file but rather I have to source my $VIMRC again for them to work as expected.

small init.vim to reproduce:

call plug#begin(stdpath('data') . '/plugged')
    Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
    Plug 'nvim-treesitter/completion-treesitter'
    Plug 'nvim-lua/completion-nvim'
call plug#end()
set completeopt=menuone,noinsert,noselect
let g:completion_enable_auto_popup = 1
let g:completion_chain_complete_list = {
\    'default': {
\        'default': [
\                    {'complete_items': ['ts']}],
\        }
\    }
autocmd BufEnter * lua require'completion'.on_attach()

after installing plugin install cpp support using :TSInstall cpp

open testfile.cpp

void function_name()
{
    int variable = 0;
    return
}

demo:

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions