Reverting to using .vim and vimfiles.
_vim is not supported by vims documentation. This reverts commit cd34039b02765dbe2dbf55d39bc9044e01746181.
This commit is contained in:
parent
91ecf6aec4
commit
f3d396b84e
@ -5,7 +5,6 @@ from functools import wraps
|
|||||||
import glob
|
import glob
|
||||||
import hashlib
|
import hashlib
|
||||||
import os
|
import os
|
||||||
import platform
|
|
||||||
import re
|
import re
|
||||||
import traceback
|
import traceback
|
||||||
|
|
||||||
@ -35,12 +34,6 @@ def _to_scratch_buffer(text):
|
|||||||
|
|
||||||
vim.buffers[-1][:] = text.splitlines()
|
vim.buffers[-1][:] = text.splitlines()
|
||||||
|
|
||||||
def _dot_vim():
|
|
||||||
"""Under windows .vim is _vim"""
|
|
||||||
if platform.system() == "Windows":
|
|
||||||
return "_vim"
|
|
||||||
return ".vim"
|
|
||||||
|
|
||||||
def err_to_scratch_buffer(f):
|
def err_to_scratch_buffer(f):
|
||||||
@wraps(f)
|
@wraps(f)
|
||||||
def wrapper(*args, **kwds):
|
def wrapper(*args, **kwds):
|
||||||
@ -1251,8 +1244,8 @@ class SnippetManager(object):
|
|||||||
snippet_dirs = ["UltiSnips"] + vim.eval("g:UltiSnipsSnippetDirectories")
|
snippet_dirs = ["UltiSnips"] + vim.eval("g:UltiSnipsSnippetDirectories")
|
||||||
us = snippet_dirs[-1]
|
us = snippet_dirs[-1]
|
||||||
|
|
||||||
path = os.path.join(home, _dot_vim(), us)
|
path = os.path.join(home, ".vim", us)
|
||||||
for dirname in [_dot_vim(), "vimfiles"]:
|
for dirname in [".vim", "vimfiles"]:
|
||||||
pth = os.path.join(home, dirname)
|
pth = os.path.join(home, dirname)
|
||||||
if pth in rtp:
|
if pth in rtp:
|
||||||
path = os.path.join(pth, us)
|
path = os.path.join(pth, us)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user