Emacs or Vi? Why the answer is neither.

Robert Clipsham robert at octarineparrot.com
Sat Jun 11 12:32:09 PDT 2011


On 11/06/2011 19:51, Jesse Phillips wrote:
> On Thu, 02 Jun 2011 17:49:52 +0100, Bruno Medeiros wrote:
>
>> It seems to be article season, and I'm on a bit of a punditry mood, so
>> here's a blog post I wrote recently:
>>
>> http://pureconcepture.blogspot.com/2011/05/emacs-or-vi-why-answer-is-
> neither.html
>>
>> It's not about D, but it's a software development issue that has popped
>> up several times here in the NG... :)
>
> I'm sorry but your conclusion is something I cannot agree with on many
> points. The big thing you miss is that most code is text. I can agree
> that Vim (I will not speak for Emacs) is not a good IDE and is bad at
> understanding the semantics of a language. But to dismiss a text editor
> for writing code because it is textual...
>
> Personally I don't like working in Java without Eclipse and in C# without
> VS or MonoDevelop. But many times I will open the file in Vim or just
> copy and past a section of code in Vim just so I can have a text editor
> to edit my text. I miss Vim in my terminal.
>
> I don't claim to know the ins and outs of an IDE, but you haven't
> convinced me. Vim's understanding of the code is zero, the closest thing
> it has is the ability to navigate tags which are generated by ctags. It
> only works for navigation and those languages supported by the program
> (just like an IDE). But some things, like a Type Hierarchy and Outline
> should be created by the documentation generator.

Actually, this is incorrect - 
http://www.vim.org/scripts/script.php?script_id=3302 - With this plugin, 
vim has full semantic completion for C/C++/Objective-C/Objective-C++.

> Some other items are very nice, but are not common during a days coding.
> I rename variables all the time, but usually these are local in scope and
> and can be done with a quick search and replace on a selection or file.
>
> Extracting a method is common and the ability to identify needed
> parameters is certainly very nice. Parameter modification is going to be
> more of a find all calls to this function then a "I'll do it for you."
> and the Content Assist (more than just auto-complete). And to this I
> generally just miss Vim more than these features, but are still the
> reasons I keep and IDE one it is available.
>
> The strangest credit you gave an IDE, "navigate to member/element above/
> below - Ctrl-Shift-Up/Down), word navigate (Ctrl-Left/Right)" This is Vim
> territory here. And you left off search, that one is simple in any
> editor, but with Vim you can be selecting text and search to where you
> want to end the selection. There are tons of ways to navigate in vim.
> Using * to find the next instance of a word, w to jump a word, % to
> navigate to the matching paren/bracket/etc.
>
> I'd like to leave you with a thought experiment. The next time you need
> to change a word (not rename a variable), or change all the content
> inside quotes and think to yourself, this would be easier in Vim. You
> don't have to believe it, but I bet you if you remember to tell yourself
> this you'll see how common it is. I've done this very thing except mine
> was "If I could just remember that command to do this."

There's far too much mouse usage in IDEs for me. You mean I have to move 
my hands away from the keyboard to do a find and replace? Pfft :<

-- 
Robert
http://octarineparrot.com/


More information about the Digitalmars-d-ide mailing list