emacs与vi的对比 我习惯用vi,但一直想尝试下emacs,屡次失败 vi下的常用的几个操作,然后找出emacs对应操作就会简单的多了
VI EMACS -- ----- Right one column k ^f Right one word w Esc,f Left one word b Esc,b Next sentence ) Esc,e Previous sentence ( Esc,a Save file :w ^x,^s Delete paragraph d} Esc,x,kill-p[TAB],[RET] Edit a new file :ename ^x,^f,name RegEx search for "foo" /foo Esc,^sfoo Repeat search n ^s,[RET] Exit :q or QQ ^x,^c Save and Exit :x ^x,^s,^x,k,[RET] Repeat last search n ^s,[RET] Paste from clipboard p ^y Delete 7 lines 7dd ^a,Esc,7,^k Undo u ^x,u or ^/ Change a letter to "x" rx ^d,x Go to line 6 :6[RET] Esc,<,Esc,5,^n ..or 6G Esc,x,goto-l[TAB][RET],6[RET] 另外和bash里面的几个快捷键一样: 到行首:^a 到行尾:^e 删除行: ^k 粘贴:^y undo: ^x u 参考: http://www.grok2.com/vi-emacs.html http://www.io.com/~dierdorf/emacsvi.html <http://www.cs.rutgers.edu/LCSR- Computing/some-docs/emacs-chart.html> http://www.wlindley.com/gnu/vi.htm
...