mirror of
https://github.com/tpope/vim-sensible.git
synced 2025-11-11 12:33:47 -05:00
Provide :DiffOrig
This seems like a weirdly specific thing to provide in a set of defaults, but since defaults.vim provides it I guess we can too. References: https://github.com/tpope/vim-sensible/issues/86
This commit is contained in:
@@ -103,6 +103,12 @@ if empty(mapcheck('<C-W>', 'i'))
|
||||
inoremap <C-W> <C-G>u<C-W>
|
||||
endif
|
||||
|
||||
" From `:help :DiffOrig`.
|
||||
if exists(":DiffOrig") != 2
|
||||
command DiffOrig vert new | set bt=nofile | r ++edit # | 0d_
|
||||
\ | diffthis | wincmd p | diffthis
|
||||
endif
|
||||
|
||||
" Load matchit.vim, but only if the user hasn't installed a newer version.
|
||||
if !exists('g:loaded_matchit') && findfile('plugin/matchit.vim', &rtp) ==# ''
|
||||
runtime! macros/matchit.vim
|
||||
|
||||
Reference in New Issue
Block a user