I know you would normally enter into vimdiff mode from the terminal with
vimdiff file1 file2. However, I frequently find myself already in vim with multiple different splits, and I'd like to run vimdiff on two specific splits, and then turn vimdiff off.
How would I go about this?
N.B. there might be other splits in my vim session that I don't want to be comparing. So I might have 4 vertical splits and I want to run vimdiff on split 1 with split 3, look at some differences, and then turn the diff off.
codmapping from tpope's unimpaired can be handy. – mMontu Mar 12 '20 at 13:07diffthis/diffoff. So it's useful if you're already using vim-unimpaired. Otherwise, it's not a problem to create such mapping yourself. – Matt Mar 12 '20 at 14:39