From 0489b5deedde0ec18588852b7db35e4ca400efd6 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Tue, 23 Sep 2014 10:01:16 +0900 Subject: [PATCH] Stricter double-comma replacement To handle paths ending with commas --- plug.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plug.vim b/plug.vim index cde2917..9b3382d 100644 --- a/plug.vim +++ b/plug.vim @@ -287,7 +287,7 @@ function! s:reorg_rtp() let rtps = map(s:loaded_names(), 's:rtp(g:plugs[v:val])') let afters = filter(map(copy(rtps), 'globpath(v:val, "after")'), 'isdirectory(v:val)') let &rtp = join(map(rtps, 's:escrtp(v:val)'), ',') - \ . substitute(','.s:middle.',', ',,', ',', '') + \ . substitute(','.s:middle.',', '^,,$', ',', '') \ . join(map(afters, 's:escrtp(v:val)'), ',') let s:prtp = &rtp