aboutsummaryrefslogtreecommitdiff
path: root/autoload/lsp_settings.vim
diff options
context:
space:
mode:
authorYasuhiro Matsumoto <mattn.jp@gmail.com>2020-01-30 02:26:24 +0900
committerYasuhiro Matsumoto <mattn.jp@gmail.com>2020-01-30 02:26:24 +0900
commite1ce15f714658b7f39e6f50c166cf2d0743a5727 (patch)
treed8de0845e07f18b0d1b3d1acbfc39aa371f45ea6 /autoload/lsp_settings.vim
parenta12bd9573bbb80d545937ffd386e94daef246204 (diff)
downloadvim-lsp-settings-e1ce15f714658b7f39e6f50c166cf2d0743a5727.tar.gz
vim-lsp-settings-e1ce15f714658b7f39e6f50c166cf2d0743a5727.tar.bz2
vim-lsp-settings-e1ce15f714658b7f39e6f50c166cf2d0743a5727.zip
Add test
Diffstat (limited to 'autoload/lsp_settings.vim')
-rw-r--r--autoload/lsp_settings.vim6
1 files changed, 5 insertions, 1 deletions
diff --git a/autoload/lsp_settings.vim b/autoload/lsp_settings.vim
index 08d1d64..867c1ff 100644
--- a/autoload/lsp_settings.vim
+++ b/autoload/lsp_settings.vim
@@ -10,7 +10,11 @@ call remove(s:settings, '$schema')
let s:ftmap = {}
function! lsp_settings#servers_dir() abort
- return get(g:, 'lsp_settings_servers_dir', s:servers_dir)
+ let l:path = fnamemodify(get(g:, 'lsp_settings_servers_dir', s:servers_dir), ':p')
+ if has('win32')
+ let l:path = substitute(l:path, '/', '\', 'g')
+ endif
+ return substitute(l:path, '[\/]$', '', '')
endfunction
function! lsp_settings#executable(cmd) abort