Ask HN: What code editor do you use?
I've been using TextMate for a few years now, but recently have been doing a lot of work in projects that have either 1) a lot of files or 2) really big files. Both of these situations cause TextMate to crawl to a halt.
I've used Emacs in the past, but something about the way in which you can navigate code just makes me feel less than efficient in it. Maybe I didn't take enough time to memorize all the required shortcuts. Mastering an editor that can be used over an ssh session certainly seems a plus.
So a question to all the coders out there: what editor do you use? Why did you choose it? What are the downsides?
142 comments
[ 4.3 ms ] story [ 222 ms ] threadI'll open the Emacs lobby with http://sites.google.com/site/steveyegge2/effective-emacs and http://sites.google.com/site/steveyegge2/the-emacs-problem
To give the illusion of fairness, here is a blogpost in which I praise Vim: http://zipwith.blogspot.com/2010/05/power-of-vim.html
not the fifty thousandth time.
http://en.wikipedia.org/wiki/Editor_war
I use it because it is simple, it gets the job done, and I don't find that I need anything more.
It's true it's missing a couple of features commonly found in code editors. But when I start thinking code folding would be useful, I take it as a sign that this file is getting too large and would be better split. Nano also obeys the simple UI principle of having a non-modal interface. I haven't used an editor with bells and whistles for some years, and I'm liking it.
Also contrary to popular belief, nano does support syntax highlighting - this just isn't enabled by default in most distros.
Now, laugh.
Well, I'll admit that was... unexpected, but I am certainly not going to laugh. After all, the best code editor is the one you feel most productive in, and you seem to have a rational explanation for it so sure, knock yourself out :-)
Did not know this! FYI, a bit of googling uncovered the following: http://code.google.com/p/nanosyntax/source/browse/trunk/synt...
If Vim wasn't always available when Nano was, I'd still use it. ;^)
Downsides? It's Windows only.
This looks like a great editor. It's proprietary, though. Damn.
Why is it that, as with Opera, every now and then you find an amazing program which, even more amazingly, is closed-source?
Emacs, however, offers minimap as well: http://www.emacswiki.org/emacs/MiniMap
I wonder how well we did compared to Sublime.
You guys have it too.
I'd love to hear more about how the projects have 1) a lot of files or 2) really big files... and how you navigate around the proj. should the really big files be broken into smaller files? etc...
Easy to use, and no holy wars.
The vim bindings are good. The app is OS X is fine. (Though I had to hack the source to make the "Go To file" not look in the history, which was bothering me with my many branches). Also removed anti-aliasing, which is awful for code IMHO.
It crashes from time to time, but I think it's the best all around choice right now for good vi bindings, sensible auto-completion, multi-language support, etc.
Plus I like that it's cross-browser and open source, in case I ever want to leave OS X for something better.
http://en.wikipedia.org/wiki/Coda_(web_development_software)...
http://www.codingmonkeys.de/subethaedit/index.html
Downsides.. IDE-ification of development. Slow startup time (wants SSD hybrid drive for this). Synchronizing plugin versions can be a pain in the ass. Fairly steep learning curve to advanced features.
i really want to give jetbrains my money but they haven't put out anything for me...yet :)
Have you ever tried IDO, http://www.emacswiki.org/emacs/InteractivelyDoThings?
And that's the worst case. If I want to see the definition of some function that the point is currently near, I just press M-. to visit it. And M-* to pop back to where I was before.
I used to use different editor for every language but I am getting more and more comfy with gedit.
So I decided to pick an editor that I could stay with for a long time, maybe forever, because it did so many things and was so configurable. It had to run on my Mac at home, the Windows nd Unix machines at work, and also on the console. It came down to Emacs or Vim. My boss was an Emacs guy, and could do wonderful things with it. But I'd had a few RSS problems, and I'd read about what Emacs did to some users' hands. So I went with Vim, and I'm very happy with it.
Really, the only downside is that I don't have Vim everywhere, so when I'm stuck somewhere that doesn't have it my hands do the wrong thing. (Like in our crappy email system. I write long messages in Vim and paste them in, but I do short ones in the mail client. And hit escape when I'm done. And then hit cancel to say that I'm not abandoning the message.)
As far as I know, the only editor more configurable than Vim is Emacs. But Vim does do a lot. I use it for Ruby, shell scripts, HTML, CSS, XML, Perl, prose, looking around in log files, and more. It handles long files easily. You can script it with its built-in language (not as powerful as ELisp, of course) or other scripting languages.
I sometimes meet people who don't know the difference between Vi and Vim. When I say I use Vim they ask how I can get by with such a limited editor that won't split windows and doesn't have tabs and so on. So when I say Vim, I mean Vim 7.2, available at vim.org.
But Emacs and other tools are worth getting familiar with as well. It's good to not be too provincial.
For most of the time it works like the best of both worlds, but it's not perfect . You can't use viper-mode in every mode and it's obviously not full vi(m) emulation. Installing the vimpulse.el script (google it) adds a lot of missing vim functionality though.
It's also just much lighter and goes with my preference of using the simplest tool that does the job.
Or you could try something called Red Car Editor (http://redcareditor.com) which proclaims to be an editor specially made for ruby/rails programmers. It looks pretty impressive, but again I couldn't get it installed properly. (I think the latest version runs on jRuby platform)
EDIT: I got inspired to try Red Car again after posting this comment. Uninstalled Ruby completely from Windows 7, installed jRUby 1.5. Red car gem installation went perfectly, but the editor is shockingly slow and unresponsive. I don't know if the same applies to linux platform, or if there is something wrong with my system (its a 2 year old laptop, and its been a long while since I have reinstalled the Windows OS)