5 ms·
A few developers I've known have made the case that they just don't see text editing speed as the bottleneck in their day-to-day work. They're perfectly happy w
by h2s 14y ago
A few developers I've known have made the case that they just don't see text editing speed as the bottleneck in their day-to-day work. They're perfectly happy with the speed at which they can edit text and that's fine. What gets to me a bit is the dismissive attitude this type of developer tends to take towards usage of Vim, as if using it makes me some sort of misguided autist.
The reason I think it matters is that there are a limited number of hours in the day. When I get home from work I have maybe three or four hours on a good day to make some progress on my own projects. If during that time I can save 10 minutes of holding down arrow keys and carefully maneouvring the mouse cursor around my code and so on, then in a week that's an extra hour or so of extra project time.
- oelmekki 14y ago> They're perfectly happy with the speed at which they can edit text and that's fine. I think they miss the point. Speed editing with vim is not about how many lines you may produce in the day. It's about the lag between the moment you think about what you want to write and the moment when it's written. Your editor should not be in the way, and that's what vim, when mastered, is all about : you simply don't think about it anymore. It's for the same reason that vim tries to reduce hand movements, so you won't feel your editor in those extra displacements.
- tyrmored 14y agoYes, I think you've nailed it. See my own reply to this comment.
- minikomi 14y agoAlso, it's extremely satisfying to record a complex macro and then 100@@ it across a wide swath of your file
- mcantor 14y agoRecording macros correctly and quickly is an art. Text objects help immensely, since they can handle a lot of edge cases in different places across your code.
- dasil003 14y agoOne of my favorite tricks was binding @q to <space>. It really speeds up playback so I don't need to necessarily count occurrences or go recursive.
- deleted 14y ago[deleted]
- mistercow 14y ago> It's about the lag between the moment you think about what you want to write and the moment when it's written. I think this is it exactly. In particular, when people start trying to incorporate typing speed into their arguments, it's a sign that they really don't understand where the bottlenecks are.
- snprbob86 14y ago> It's about the lag between the moment you think about what you want to write and the moment when it's written. Agree 100%. Every other editor just feels like swimming in molasses to me.
- tyrmored 14y agoThe time you can save with Vim can be significant, depending on the task. However what I think is far more valuable is that Vim doesn't get in the way; it doesn't impede the all-important "flow", and perhaps most importantly it stops you getting bored. When your muscle memory develops to a certain point, using Vim becomes a subconscious thing. You don't have to think about how to copy all the text in between two quotes and paste it at the end of the document; there are already words in Vim's vocabulary for doing that, so you just do it. You don't need to build mental steps because it becomes completely natural, as easy as typing natural English; and just like in natural language, the more words you know well, the more likely you are to be able to use the right word at the right time, using language effectively. Equally valuable: Vim takes the repetition out of everything. A technically versed creative mind is wasted on any repetitive task. You should never, ever have to do anything more than twice in development. You should be able to repeat and automate tasks and scarcely think about it. In Vim, this need is met by skilful use of . to repeat actions and q to record macros. When you edit text optimally, you can concentrate on the task at hand, and the editor stays out of your way and does exactly what you need it to. You don't need to build the "subtask" of making your editor do what you want; you can just do it. I think that people who focus on the time Vim does or doesn't save you are missing the point.
- jamesbritt 14y agoA technically versed creative mind is wasted on any repetitive task. I find that certain repetitive tasks help free my mind up to wander around, think more abstractly about my code. What's important to me is that my tools give me a choice about this.
- evoxed 14y agoSadly every minute gained with vim/emacs/anything is another 10 minutes wasted arguing about it... Disclaimer: I use vim because I just like it. The key to becoming more efficient in my opinion? Learning to type faster. Saves you all kinda trouble when you're posting to HN as well ;)
- Derbasti 14y agoVery true. I think the key to efficiency is alway happiness. When you're happy with your environment, you most likely can work without worries or disturbances and are thus efficient. So, use the tools that make you happy. Personally, I use Emacs and I love it. But I don't think that Emacs inherently makes me more efficient than, say Vim or Sublime Text. That said, you should use a tool with sufficient power so you are not limited by it. So no Notepad, sorry.
- npsimons 14y agoIt's more than just time savings; remember in "Peopleware" how they said even a one minute interruption really meant 15+ minutes of getting back into flow? If your dev environment gets in your way every time you use it, it will be like trying to drive a stickshift if you don't know how. As was said in "Pragmatic Programmer", your editor should be an extension of your hand; if you're always having to reach for the mouse to do something, it's like a cache miss (another great analogy, from Steve Yegge's "Effective Emacs"). While this doesn't have a whole lot to do with a specific editor, I have to say that most "modern" IDE's I've ever seen suffer from too much mousing, and you can recreate their useful features in Emacs. I still love vi (and use it for quick sysadmin tasks), but there's a reason I have the Firemacs addon installed in Firefox.
- henrik_w 14y agoGood references from Peopleware and Steve Yegge! As for IDEs and mousing: I hate when I have to reach for the mouse - I try to do as much as I can with keyboard short-cuts. I'm currently using Intellij IDEA for Java coding, and it is definitely possible to do a lot without the mouse. The big advantage is navigation. Most of the time for me is spent navigating the existing code, and there Intellij IDEA really shines compared to just a text editor. I've written this up in more detail here: http://henrikwarne.com/2012/06/17/programmer-productivity-emacs-versus-intellij-idea/ http://henrikwarne.com/2012/06/17/programmer-productivity-em...
- gizmo686 14y agoThe reason I like vim isn't so much about editing speed as reading speed. I spend a large amount of time in source code for projects where I only want to check or change some very minor things. Always being a keystroke away from jumping to anywhere in the code turns this from a boring, hellish ordeal, into an quick, exciting exploration of code. Vim also has the perk of being terminal, so it integrates seemlessly with my flow when want to use cmdline tools (also often). Being able to refactor large amounts of code quickly, and with minimal repatition is also fun. Interestingly, despite my strong prefence for vim, and the fact that I spend most of my time in it, when I am actually writing new code, the only time I hit ESC (caps-lock) is to save.
- Evbn 14y agoGet better coworkers. I have some, and we are hiring.