1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-01-23 10:30:05 +08:00

Use register + only when has unnamedplus (#2231)

close #2202
This commit is contained in:
Wang Shidong 2018-10-03 15:55:37 +08:00 committed by GitHub
parent 3fcf185924
commit c4be5b44d4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -150,12 +150,21 @@ function! SpaceVim#default#keyBindings() abort
endif
" yank and paste
xnoremap <Leader>y "+y
xnoremap <Leader>d "+d
nnoremap <Leader>p "+p
nnoremap <Leader>P "+P
xnoremap <Leader>p "+p
xnoremap <Leader>P "+P
if has('unnamedplus')
xnoremap <Leader>y "+y
xnoremap <Leader>d "+d
nnoremap <Leader>p "+p
nnoremap <Leader>P "+P
xnoremap <Leader>p "+p
xnoremap <Leader>P "+P
else
xnoremap <Leader>y "*y
xnoremap <Leader>d "*d
nnoremap <Leader>p "*p
nnoremap <Leader>P "*P
xnoremap <Leader>p "*p
xnoremap <Leader>P "*P
endif
" Location list movement