Update vim-plug

This commit is contained in:
Julian Ospald 2018-08-15 00:57:55 +08:00
parent 841afeb278
commit 8ca26b851d
No known key found for this signature in database
GPG Key ID: 511B62C09D50CD28
1 changed files with 11 additions and 3 deletions

View File

@ -96,7 +96,7 @@ let s:plug_src = 'https://github.com/junegunn/vim-plug.git'
let s:plug_tab = get(s:, 'plug_tab', -1)
let s:plug_buf = get(s:, 'plug_buf', -1)
let s:mac_gui = has('gui_macvim') && has('gui_running')
let s:is_win = has('win32') || has('win64')
let s:is_win = has('win32')
let s:nvim = has('nvim-0.2') || (has('nvim') && exists('*jobwait') && !s:is_win)
let s:vim8 = has('patch-8.0.0039') && exists('*job_start')
let s:me = resolve(expand('<sfile>:p'))
@ -763,6 +763,9 @@ function! s:prepare(...)
execute 'silent! unmap <buffer>' k
endfor
setlocal buftype=nofile bufhidden=wipe nobuflisted nolist noswapfile nowrap cursorline modifiable nospell
if exists('+colorcolumn')
setlocal colorcolumn=
endif
setf vim-plug
if exists('g:syntax_on')
call s:syntax()
@ -2426,8 +2429,13 @@ function! s:diff()
\ . (cnts[1] ? printf(' %d plugin(s) have pending updates.', cnts[1]) : ''))
if cnts[0] || cnts[1]
nnoremap <silent> <buffer> <cr> :silent! call <SID>preview_commit()<cr>
nnoremap <silent> <buffer> o :silent! call <SID>preview_commit()<cr>
nnoremap <silent> <buffer> <plug>(plug-preview) :silent! call <SID>preview_commit()<cr>
if empty(maparg("\<cr>", 'n'))
nmap <buffer> <cr> <plug>(plug-preview)
endif
if empty(maparg('o', 'n'))
nmap <buffer> o <plug>(plug-preview)
endif
endif
if cnts[0]
nnoremap <silent> <buffer> X :call <SID>revert()<cr>