Search code examples
vimultisnips

UltiSnips doesn't automatically reload changes to snippets file


(Documenting this here because I couldn't find a good answer online.)

When using UltiSnips, the documentation says (2:12 in this screencast) that writing the .snippets file is enough to cause an automatic reload of the snippet. However, this doesn't work for me. What's happening?


Solution

  • I had this question myself, as frequently updating my own .snippets files and not having them immediately available is unpleasant. After some experiments I discovered the answer:

    :call UltiSnips#RefreshSnippets()
    

    In case you are curious, I found it by typing :call <C-d> (a very long list, by the way).

    However, this command does not update the autocompletion list of YouCompleteMe (which is mostly irrelevant, but sometimes you might want to browse through your options with description next to it).