We’re rewarding the question askers & reputations are being recalculated! Read more.
3

Based on tracyone's vim configuration I have created a fork of necovim that automatically registers as vim omnifunc. Just add the plugin with your favorite vim plugin manager and it will work out of the box with YouCompleteMe.


1

The following works elegantly without the need for too many bindings. function! s:CRComplete() if empty(v:completed_item) execute "norm! i\<CR>" endif endfunction inoremap <CR> <LEFT><RIGHT><C-O>:call <SID>CRComplete()<CR> Edits: In view of Hotschke's answer, the check for v:completed_item in my function ...


1

Ycm can cooperate with Shougo/neco-vim autocmd FileType vim setlocal omnifunc=te#complete#vim_complete function! te#complete#vim_complete( findstart, base ) abort let line_prefix = s:get_input() if a:findstart let ret = necovim#get_complete_position( line_prefix ) if ret < 0 return col( '.' ) " default to current endif return ret ...


1

You can do :%s/<[^>]*>//g If you want to use it multiple times make a map for it like nnoremap g<space> :%s/<[^>]*>//g<CR> So you can use it by pressing g (you can change that of course)


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