mirror of
https://github.com/junegunn/vim-plug.git
synced 2026-10-09 06:45:48 +08:00
Strip trailing slash from g:plug_home
This commit is contained in:
1 parent
3e65d146ad
commit
23748f115f
2 files changed
+26
-10
No files matched your search
@@ -58,8 +58,9 @@ let s:is_win = has('win32') || has('win64')
|
||||
let s:me = expand('<sfile>:p')
|
||||
|
||||
function! plug#begin(...)
|
||||
let home = a:0 > 0 ? fnamemodify(a:1, ':p') :
|
||||
\ get(g:, 'plug_home', split(&rtp, ',')[0].'/plugged')
|
||||
let home = s:path(
|
||||
\ a:0 > 0 ? fnamemodify(a:1, ':p') :
|
||||
\ get(g:, 'plug_home', split(&rtp, ',')[0].'/plugged'))
|
||||
if !isdirectory(home)
|
||||
try
|
||||
call mkdir(home, 'p')
|
||||
|
||||
Reference in new issue
Block a user