Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
例如,假设我在 Vim 中愉快地编辑文档时不小心点击了 gg。然后我在文档的第一行结束,当然我不知道哪一行是我上次编辑的确切行。有没有办法神奇地回到 gg 跳转之前的最后一个编辑行?
快捷方式是Ctrl+O(即字母“O”)移回之前的位置。
Ctrl+O
并Ctrl+I撤消该操作(移回按 之前的位置Ctrl+O)。
Ctrl+I
这些可以多次使用,例如浏览器上的后退和前进按钮,以移动到以前“跳转到”的位置。
要在当前位置和上次跳跃的位置之间来回跳动,可以使用``(两个反引号)。请参阅:h ``此列表和其他跳转快捷方式的列表。
``
:h ``