I have used many text editors in more than a decade long programming career. As I am working on Ruby on Rails my obvious choice was TextMate. I used it for a while and thought to give RubyMine a spin. Since I was a Java developer for most of my career, I extensively used IntelliJ IDEA. No doubt it is the best IDE for Java developers out there! Eclipse and Netbeans are good but they have no upper hand when it comes to extensive features which IDEA provides. That is not the point of this post so I will skip writing about it.
RubyMine and IntelliJ Idea share most of the key-bindings, a natural bonus for me. I didn't need to learn anything new to get productive in RubyMine. I loved it. Very soon I realized, all the features which made IDEA so great, are not very important in Ruby on Rails! e.g. refactorings, type checking, name changes etc. Since Ruby is dynamic language, type checking is not required. When it comes to refactoring variable names, you can't trust an IDE to make those changes by itself! Properties hidden behind meta-programmed methods are tricky to find and rename accurately. So in short all the great powers which IDEA boasts, are not required.
Did I mention RubyMine is resource heavy? :)
So I went back to TextMate tried it for second run. TextMate is great editor. Period. I enjoyed working in that software a lot. It has almost all the features any developer will need. It got its popularity in Rails community but it is useful for anybody for any text-editing needs.
When it came to searching full project or loading large files, TextMate isn't the king of the land. It often shows you pretty spinning wheel and lets you wait for long times. Sometimes it just refuses to load large files which you accidentally open. e.g log files.
So I thought, let's try VIM. I used VIM for last 10 years as my terminal editor of choice. My usage was very limited and not VIM specific. I could have done all the editing using pico without a doubt. So I wouldn't call myself a power user of VIM for 10 years.
I met a guy on my last project (Selvakumar Natesan) who introduced me to MacVim as Rails IDE. I used it for a while and loved it a lot. Although, I was fairly naïve in terms of its usage. After a while the enthusiasm to use VIM faded away and I was back to TextMate. On my current gig, I met two guys who were using VIM regularly (Priyank Gupta and Carl Leiby). This gave me another reason to start using it, and I did it this time!
I realized that I can't just depend on my pair to drive most power from VIM where I just stare at them and appreciate VIM. I needed to learn it and get used to that style. So I did spend some time reading cheat-sheet (more time in practicing!) and watching few screencasts where people showed few cool tricks.
After spending couple of weeks working daily on VIM, now I am fully productive and don't have any reasons to switch to TextMate or Rubymine anytime soon. I think I found my soul-editor. :)
If you're interested in switching to VIM as well, here are few links which helped me a lot during this transition:
- A Starting Guide to VIM from Textmate: This guide will get you rolling pretty quickly on VIM if you are on Mac.
- Janus VIM Configuration Bundle: Undoubtfully most comprehensive set of tools for RoR development using VIM. I use non-customized version of this currently.
- PLAY BY PLAY: GARY BERNHARDT : Very good screencast if you want to see a pro using VIM in 100 min video. I paid $12 for that and it was totally worth it! There are bunch screencasts available for free as well. Look for them.
After learning this, all I can say, "It is easier than you think!"