Emacs和Vim之间有什么实际的、客观的区别?例如,使用一个可以做而另一个不行(或者使用一个比另一个更容易做)?为了选择一门课程,我应该知道些什么?


当前回答

首先,Vi(原始实现)今天不使用。你说的是一些Vim推导。

要扩展Vim功能,必须重新编译Vim, Emacs则不必。

Emacs在self中有Vim (viper模式)。

Emacs通常需要手动安装,Vim通常预安装在所有Unix之类的操作系统上(但如果你有ssh访问主机的tramp模式win Vim:)。

如果你尝试Vim,那么你讨厌Emacs,所以先从Emacs开始。

也请阅读http://www.dina.dk/~abraham/religion/vi-tutorial.html(链接下拉,所以使用这个)

hxxp中的答案搜索://en.wikipedia.org/wiki/Editor_war

其他回答

对我来说,emacs的优点是,

tramp模式允许您通过ssh编辑远程文件。就像本地文件一样。 Tramp-mode + dired =全功能SFTP客户端 支持您需要的所有语言。 内置的终端模拟器(术语模式),所以我可以继续编码,而无需在应用程序之间切换。 可扩展性任何你不喜欢的东西都可以用lisp来改变。

VI总是可用的,并且将在最残缺的、单用户模式、坏的图形、没有键图、慢的链接机器上运行——因此,仅仅为了系统管理任务,了解如何在它中编辑简单的文件是值得的。

Emacs是一个编辑器中的完整用户界面。其思想是在启动机器时启动Emacs,并且永远不要离开它。可能会有数千个会话。

与使用GUI编辑器/IDE和使用python/awk/等来完成额外任务相比,学习Emacs的功能是否值得,取决于你自己。

If you are looking for an objective analysis of both the editors, look at their origins and the philosophy behind their respective designs. Think, which one would suit you better and learn it (and learn it and learn it, because it takes time before you being to discover its true utility as against any IDE). An Introduction to Display Editing with Vi was written by Bill Joy and Mark Horton and he explains why he choose modal design and rationale for various key strokes ( it helps me to remember that CTRL-W +W (will switch to next Window and it will same for CTRL W+ CTRL W, just in case you held the CTRL key for a longer duration.

这里有一个Emacs时间轴的链接,并有对Multics Emacs论文的参考。这是一篇关于Emacs的RMS论文,我看到重点在可编程文本编辑器上(甚至早在1981年或更早的时候)。

我没有读过emacs的论文,但是读过Bill Joy的vi论文几次。 两者都是旧的,但你仍然会得到哲学,你可以选择使用当前的工具(vim 7。X还是emacs 25?)

编辑:我忘了说,阅读这两篇论文需要耐心和想象力,因为它会让你在阅读时回到过去。但这是值得的。

在你的问题中,你没有提到你想让它用Lisp编程!但是当你评论你的回答时,我明白你实际上想要一个LISP编程接口。

对于这个精确的任务,忘记Vi吧。Emacs与LISP的集成非常棒!你应该使用SLIME。然后,您将与REPL进行出色的集成,能够将函数、缓冲区或文件直接计算到emacs缓冲区中运行的解释器中,以及更多…

Seems an answer has been selected already, but the big difference to me has always been the modal vs. non-modal. Vim is modal, which means that it makes optimizations based on a specific set of usage modes. At least that's how I've always looked at it. This makes using Vim a different experience because instead of having a work area that you type code in, you really are telling an environment to act on the text. This is why people say things like with Vim you really are learning a language. The :wq and :s/foo/bar is all part of a shell like environment that edits and reads text.

Emacs on the other hand is much closer to most editors/word processors/etc. you see today. You have a workspace that has a highly programmable interface. That is why you see things like email, irc, shells, etc. As a programmer it is easy to think in terms of saying "take the line number I'm on and do something with the information". The desire to leave the editor becomes less because instead of having to quit, open some other app/language and do things on some text, you have Emacs where you can do these things within the scope of your editor.

这两种观点并不一定是对立的,只是它们揭示了两个不同的焦点。就我个人而言,我使用Emacs,但我见过非常了解Vim的人,他们可以诚实地说,选择哪种并不重要。我首先尝试了Vim,但Emacs最终支持了我。的确,无论您选择什么,您都应该至少在一定程度上精通Vim,因为它总是可用的。