diff options
author | Hugues Hiegel <hugues.hiegel@anevia.com> | 2016-02-16 12:56:14 +0100 |
---|---|---|
committer | Hugues Hiegel <hugues.hiegel@anevia.com> | 2016-03-09 12:39:20 +0100 |
commit | 2fa40df23275cce7f30e8f0d46be6b3375eba676 (patch) | |
tree | 361f42b7afc9929b1c45210d694239d22e078c5c /plugin | |
parent | b4a3e36ecca719fc76dcbb7cd5a7b534740c1475 (diff) |
[bundle] moved linediff as bundle
Diffstat (limited to 'plugin')
-rw-r--r-- | plugin/linediff.vim | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/plugin/linediff.vim b/plugin/linediff.vim deleted file mode 100644 index f154d6d..0000000 --- a/plugin/linediff.vim +++ /dev/null @@ -1,48 +0,0 @@ -if exists("g:loaded_linediff") || &cp - finish -endif - -let g:loaded_linediff = '0.1.1' " version number -let s:keepcpo = &cpo -set cpo&vim - -" Initialized lazily to avoid executing the autoload file before it's really -" needed. -function! s:Init() - if !exists('s:differ_one') - let s:differ_one = linediff#differ#New('linediff_one', 1) - let s:differ_two = linediff#differ#New('linediff_two', 2) - endif -endfunction - -command! -range Linediff call s:Linediff(<line1>, <line2>) -function! s:Linediff(from, to) - call s:Init() - - if s:differ_one.IsBlank() - call s:differ_one.Init(a:from, a:to) - elseif s:differ_two.IsBlank() - call s:differ_two.Init(a:from, a:to) - - call s:PerformDiff(s:differ_one, s:differ_two) - else - call s:differ_one.Reset() - call s:differ_two.Reset() - - call s:Linediff(a:from, a:to) - endif -endfunction - -command! LinediffReset call s:LinediffReset() -function! s:LinediffReset() - call s:differ_one.Reset() - call s:differ_two.Reset() -endfunction - -function! s:PerformDiff(one, two) - call a:one.CreateDiffBuffer("tabedit") - call a:two.CreateDiffBuffer("rightbelow vsplit") - - let a:one.other_differ = a:two - let a:two.other_differ = a:one -endfunction |