5

Overview Ultisnips supports vimscript interpolation. To illustrate, the todo snippet for a block comment will have following structure: snippet todob "todo with block comment" b `!v {BLOCK_COMMENT_START}`TODO: $1`!v {BLOCK_COMMENT_END}` endsnippet where {BLOCK_COMMENT_START} and {BLOCK_COMMENT_END} are vimscript expressions, that we have to ...


3

It's not available in Vim. However, there is a fork called Vim-CLPUM. You need its clpum branch, which is 2 years behind Vim's master at the moment. If you really like this feature, maybe you could help h-east with testing it or in some other way.


3

EDIT Actually junegunn already has everything covered for you. Since you already use fzf you can add this to your vimrc: imap <c-x><c-l> <plug>(fzf-complete-line) And now <c-x><c-l> will use fzf to fuzzy match your line against the existing one in your buffers and complete directly in your buffer. See fzf's readme for the list ...


3

You need this map: inoremap <expr> <TAB> pumvisible() ? "<C-y>" : "<TAB>" If PUM (complete menu) is visible, then execute <C-y> (which selects an item), otherwise, do a normal tab.


3

I'm not entirely sure this does what you want, because you didn't provide tests in the form of expected inputs/outputs, but in case you're interested in a Vim script solution, here's a starting point: vim9script def PathRelativeToCurfile(path: string, curfile: string): string var head_of_curfile: string = fnamemodify(curfile, ':h') .. '/' # the path ...


3

The advantage of generic plugins such as CoC is that they work for a wide range of filetypes; for example I normally write most of my code in Go and use the Go Language Server for this (via vim-lsc, which is more or less similar to CoC). This week I did some C programming though, and by just installing the clangd language server on my system vim-lsc also ...


2

Hey not a long time ago I was also looking to have the same setup as yours and ended up with this config. Although I ended up using <c-j> and <c-k> for navigating the completion list and also for snippet jumps. let g:coc_snippet_next = '' let g:coc_snippet_prev = '' inoremap <expr> <c-j> \ pumvisible() ? "\<c-n>" : ...


2

Nope, not a Vim answer. AFAIK, though it's the best solution available. absolute->relative is needed a lot less frequently then relative->absolute so I expect your choices will be pretty limited. That being said, there's an option that mostly meets your requirements with the grey area being whether it's distributed widely enough for you. I'm talking ...


2

A simple fix is to use the third argument of input, which is a {completion} type (list at :help :command-completion): … const bufname = input('warp: ', '', 'buffer') … (I used const instead of let, too.)


2

CoC, the Conqueror of Completion also deserves a mention. It is very advanced, comparable to VSCode's Intellisense, with extensions tailored to each language. It works with Vim 8 and with Neovim. If you are not using a plugin manager, then the initial setup may take a little effort: You will need node installed, then run npm run build in CoC's home folder ...


2

You can use Ctrl+E to cancel completion and go back to where you were before you started it. See :help complete_CTRL-E: When completion is active you can use CTRL-E to stop it and go back to the originally typed text. The CTRL-E will not be inserted.


2

Not exactly what OP asked but... maybe someone will find this useful. There are countless plugins (commonly referred as "pickers") that allow user to pick an item from (vertical) popup menu and to execute some arbitrary command afterwards (vim-clap, nvim-telescope, you name it). Probably many of us also tried to create "fast buffer switch"...


2

Thank you for posting this question. The same thing is bothering me as well. At first, I thought there was a new plugin - wilder, but it appears (to me) that the vertical-nature is not given. I did not try to install the python dependencies. Nonetheless, I am recommending to try the following pair of options: set nowildmenu set wildmode=list:full This is ...


1

Instead of caching, you can try some techniques to avoid searching through so many files. Because the 'complete' setting applies to completion triggered by ctrl-p or ctrl-n, try one of auto-complete modes triggered by ctrl-x. For instance, ctrl-x ctrl-n is keyword completion only for the current buffer. This will avoid searching through all other buffers ...


1

My mistake at line # 148 -- Setup lspconfig. 148 require('lspconfig')[tsserver].setup { 149 capabilities = require('cmp_nvim_lsp').update_capabilities(vim.lsp.protocol.make_client_capabilities()) 150 } This should be: require('lspconfig')['tsserver'].setup { I didn't know the string tsserver was supposed to be a string litteral.


1

Not a YCM answer, but Ctrl-x Ctrl-i will complete from included files, assuming path/include/etc. are configured correctly. See :help compl-keyword for more.


1

Hidden files do not automatically show up in wildcard expansions unless there's a leading dot, but this behavior can be switched on in the source code. Let's dive in. src/vim.h defines a number of flags that determine how wildcard expansions are to be performed. One of them is EW_DODOT, which if set will cause wildcard expansions to pick up dot files ...


1

I ended up writing this little script: " --Warp: fast buffer switch function Warp(...) let bufname = a:1 if bufname == "" b# else if bufname == "d" echo("d") %bd|e#|bd# else exe "b " . bufname endif endif endfunction command! -nargs=? -complete=buffer Warp :call Warp(<q-...


1

Yes, there is: Ctrl+p to move up. Ctrl+n to move down. Furthermore, these keybindings are not special to vscodevim, but are standard to most vim editors.


1

I’ve got a plugin that does this for maps but only for mappings registered through the plugin.


1

It is likely that there are other commands that start with :Vim but not :Vimspector that are being offered in the completion, hence why it stops there. Natively, vim offers the :VimballList command. You can see with :h :VimballList that this comes from the pi_vimball standard plugin. That page will tell you that if you do not wish to use this plugin you ...


1

If using Coc - formatOnType should be enabled and special i-keybinding set, details here https://github.com/neoclide/coc-pairs/issues/13 If not - https://github.com/jiangmiao/auto-pairs


1

it should be let g:ycm_show_diagnostics_ui = 0


1

You could use https://github.com/cwfoo/vim-text-omnicomplete. It is an omnicomplete plugin for English words, and it is automatically enabled in text files (*.txt, README). Advantages over Vim's dictionary completion: It orders its suggestions by word frequency. More common words would be suggested before less common ones. It is able to suggest matches ...


Only top voted, non community-wiki answers of a minimum length are eligible