Hacker News new | ask | show | jobs
by randylahey 3187 days ago
Really? I use it frequently while programming in Vim. Definitely one of my top ten operations.
1 comments

Uh, yeah, why would you? You can easily delete a word at a time and then type in what you wanted instead.
All I can think of is adding text into whitespace preceding alignment; but that's not such a common operation (at least not in my daily usage).
cw is shorter than dwi?
Well, like anyone with their head screwed on straight, I use emacs and don't know all the vim shortcuts.
Heh, as you can see from the other comments, I don't know all the vi commands either. Just a few essentials. I'd assumed from the comment you were a vi person and probably knew more vi than me.

I don't use vi for coding, just quick file edits on the console. I was xemacs for a very long time in college and thereafter - to the point of writing elisp to manipulate xml files, but eventually my Java day job pushed me towards a full IDE. Java is kinda unbearable without it.

I still occasionally turn to emacs for a few things I can't get elsewhere (editing binaries, large files, and doing search and replace in a narrowed buffer), but it's no longer my primary editor or mail reader. I may pick it up again for clojure coding, though.

Yeah, I'm a full IDE guy too but if I'm editing something that where that wouldn't make sense it's back to emacs with me. IntelliJ also supports emacs bindings. :)
‘cw’ isn't overwrite, ‘cw’ is change word. ‘R’ is overwrite. I use ‘r’ sometimes, mostly for things like ‘yypfxry’, but I can't remember the last time I used ‘R’.