为什么VimDiff如此有限?

Raf*_*fid 0 vim vimdiff

凭借Vim的所有高级编辑功能,我发现很难相信VimDiff无法从右/左复制!还有什么可以使用difftool?任何的想法?VimDiff有什么功能?

此外,我甚至没有看到一种方式转移到下一个/ prev差异!!

Luc*_*tte 23

每一件事情是在帮助解释...( ,do,dp,)]c[c

:h diff
Run Code Online (Sandbox Code Playgroud)

:h :h 也是你的朋友.


bel*_*qua 8

您需要使用dodp满足您的复制需求; 这些代表当前窗口中的'put',并从其他窗口'获取'.(这假设是双分裂差异.)

要转移到下一个/上一个区别,请使用]c[c.

以下是我使用的基本命令,尽可能使用助记符:

dp - 'put' the changes from the current window into the other window.
do - 'obtain' the changes from other window.
]c - Go to change after (ending/next bracket) -- move to the next difference.
[c - Go to change before(opening/previous bracket) -- move to the previous diff.
zo - 'open' a section of folded text.
zc - 'close' a foldable text section.
Ctrl-W+Ctrl W - (That's ^W twice.) Jump to the other window.
:diffupdate - updates diff based on changes .
Run Code Online (Sandbox Code Playgroud)