13 votes
Accepted

How to install YouCompleteMe with Clang completer offline?

I did the following to install (Although I could copy the whole ~/.vim directory to the new place instead of steps 3-6): Install vim 7.4: brew install vim Note: If you are using mac operating ...
user avatar
11 votes
Accepted

What's the correct way to install YouComplete using vim-plug in vim/nvim?

neovim version 0.1 has breaking changes. It uses directory ~/.config/nvim (On Mac OS X. Linux or Windows may use slightly different paths.) If you want your neovim configuration independent of vim ...
user avatar
  • 226
9 votes

Why doesn't YouCompleteMe complete function paramters?

Finally found it! Completing parameters is not a part of the YCM behaviour. See this YCM issue. There's an old fork from oblitum which could grant this feature. That's what misled me. Unfortunately,...
user avatar
  • 191
8 votes
Accepted

YouCompleteMe in non-code files yields -- User defined completion (^U^N^P) Pattern not found

The command g:ycm_filetype_whitelist was the one I needed! let g:ycm_filetype_whitelist = { 'cpp': 1, 'c': 1, 'python':1 } Finally, to get ride of this message altogether, the answer is in the FAQ. ...
user avatar
8 votes

Is there a way to install youcompleteme plugin using vim 8.0 default plugin manager?

mkdir -p ~/.vim/pack/plugins/opt git clone https://github.com/Valloric/YouCompleteMe ~/.vim/pack/plugins/opt/YouCompleteMe cd ~/.vim/pack/plugins/opt/YouCompleteMe && git submodule update --...
user avatar
  • 335
8 votes
Accepted

Getting Python support for gVim 8.1 (Windows 10)

With dynamic python, the name of the python DLL (or shared object on Unix) is defined at compile time. In your case it is python36.dll. As you now want to use a different python version, this name ...
user avatar
  • 8,675
7 votes
Accepted

How can I keep the gutter width constant when using YouCompleteMe?

Install Vim 8 (released a few hours ago), and set signcolumn: set signcolumn=yes This is a actually available in Vim 7.4.2201 and later, but you really should go for the major release instead.
user avatar
  • 3,879
6 votes
Accepted

How to disable YouCompleteMe's error checking?

The g:ycm_show_diagnostics_ui variable controls this: The *g:ycm_show_diagnostics_ui* option When set, this option turns on YCM's diagnostic display features. See the _Diagnostic display_ section in ...
user avatar
  • 23.9k
5 votes
Accepted

Adding ctags for a 3rd party library

You could use this to tell Vim to look recursively for tags files under /usr/include/: set tags+=/usr/include/**/tags For the generation part, I'm afraid you will still have to generate tags files ...
user avatar
  • 33.1k
5 votes
Accepted

What does an `autocmd User` do?

In my understanding, that example creates a User autocommand named YouCompleteMe which will be fired by vim-plug itself, in order to load the plugin on demand. If I'm not mistaken, here's the place ...
user avatar
  • 9,340
5 votes

How do I copy the error message I get from YCM

If YCM uses the proper mechanisms, that message should be in either v:statusmsg or v:errmsg. You can put those values into the system clipboard via: :let @+ = v:statusmsg
user avatar
  • 16.9k
4 votes
Accepted

How can I limit number of suggestions when using YouCompleteMe?

Whether or not you display all of the suggestions probably won't affect the lag. YouCompleteMe will search through all of the possible completions anyway. There is no way to display the "10 top ...
user avatar
  • 766
4 votes

Make column for signs permanent in gVim

Apart from the hack with adding a dummy sign (which is what most sign plugins do), there is nothing that can be done. If that bothers you, cheer at vim-dev, that my patch gets integraged. (Als ...
user avatar
4 votes
Accepted

Why my dot key doesn't work properly in insert mode?

For anyone else stumbling upon this; the reason why :iunmap didn't work is found in :help E31: - If the mapping is buffer-local you need to use ":unmap <buffer>". YouCompleteMe seems to just ...
user avatar
  • 647
4 votes
Accepted

E464: Ambiguous use of user-defined command: Plug 'rdnetto/YCM-Generator' , { 'branch': 'stable'}

The error message comes from the last line of your vimrc: Plug 'rdnetto/YCM-Generator' , { 'branch': 'stable'} This is a call to the Plug command of the Vim-plug plugin manager. To work, this line ...
user avatar
  • 46.5k
3 votes
Accepted

How can I show the command line YouCompleteMe is using to compile my file?

Digging through the ycm-users Google group, I found a post by someone else who was trying to debug their .ycm_extra_conf.py flag settings and was using :YcmDebugInfo to get information about the flags ...
user avatar
  • 61
3 votes
Accepted

Make column for signs permanent in gVim

You can do what some plugins do and create a dummy sign: sign define Dummy autocmd VimEnter,SessionLoadPost,BufRead * execute 'sign place 97349278 line=9999 name=Dummy buffer='.bufnr('%') All this ...
user avatar
  • 6,380
3 votes
Accepted

How do I complete Python3 with YouCompleteMe?

I tried to update YCM and recompile it. Now, it is fine. Python3 support was added for last month and I just updated YCM last month.
user avatar
  • 195
3 votes
Accepted

Installation of YouCompleteMe

After some tries, I finally find out what's going on with my installation of vim-youcompleteme, and I decided to answer my own question. First, building from source is not a good idea, unless you ...
user avatar
  • 267
3 votes

What's the correct way to install YouComplete using vim-plug in vim/nvim?

It's installed in the .vim/ dir, because of call plug#begin('~/.vim/plugged') try: call plug#begin('~/.config/nvim/plugged') Instead, as answered above
user avatar
3 votes

What's the correct way to install YouComplete using vim-plug in vim/nvim?

I managed to install it. What I did was install python for neovim using pip install neovim The next thing I did was :PlugInstall YouCompleteMe from within neovim and it started installing as it ...
user avatar
  • 373
3 votes
Accepted

Re-activation of vim-youcompleteme

The addon packages in Debian/Ubuntu are typically managed using the vim-addon-manager package. Once an addon package is installed, you run vam install <addon> to enable it in your user's config....
user avatar
  • 10.4k
3 votes

How to get Youcompleteme to work with Vimscript?

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 ...
user avatar
3 votes

Sharing gutter space between line numbers and YCM markers

You could try and use DynamicSigns. The documentation includes an example to show relative line numbers every 5 lines. Maybe you can adopt the example and use this plugin combined with YCM.
user avatar
  • 919
3 votes
Accepted

Why python autocompletion does not work if path to python binary is taken from variable?

Almost all Unix commandline programs end their output with a trailing newline, and Vim's system() doesn't remove this. This can be a difficult to spot with a regular :echo; the easiest way to check ...
user avatar
3 votes

Auto-complete popup menu: make Enter trigger newline if no item was selected

To add to existing answers, I found empty(v:completed_item) to be unreliable, and sometimes it will be empty even though I have something selected in the pum. What worked for me was to use ...
user avatar
  • 31
3 votes

Understanding YouCompleteMe's 'Configuring through Vim Options' Mechanics

So, I did a bit of research and they were very helpful at the YouCompleteMe gist chat room. Here is what I know now. Also this is probably only python-completion specific, but I am sure the mechanics ...
user avatar
  • 677
3 votes
Accepted

Completion pop-ups hijack arrow keys. Any way to disable that?

Remap <up> key to close popup menu and move cursor up when popup menu is visible: inoremap <expr> <up> pumvisible() ? '<c-e><up>' : '<up>' :h :map-expression :h ...
user avatar
  • 5,908
3 votes

How do I display a Python docstring in Vim

What program is called when K is pressed is set by keywordprg. By default, this is set to man (the linux manual). Changing it to pydoc so as to get Python documentation will do the trick, but then you ...
user avatar
  • 171
3 votes
Accepted

Disabling hint popup

let g:ycm_auto_hover='' This disables the popup.
user avatar

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