6

What is the correct way to change where UltiSnips searches for snippets? I tried the lines below with no success:

let g:UltiSnipsSnippetsDir = "/newfolder/snippets/"
let g:UltiSnipsSnippetDirectories=["UltiSnipsNewDir"]
1
  • 6
    Have you read the corresponding doc at :h UltiSnips-snippet-search-path? It precises that your directory UltiSnipsNewDir must be a sub directory of one of them defined in runtimepath, is your new directory placed in the right place?
    – statox
    Aug 6, 2015 at 8:21

1 Answer 1

2

I don't know what setting g:UltiSnipsSnippetsDir actually does either UltiSnip's documentation is misleading or this is a bug. However, adding your directory to rtp by itself does what you want.

set rtp+=/newfolder/snippets
let g:UltiSnipsSnippetDirectories=["UltiSnipsNewDir"]

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.