Re:Best of Vim Tips
by dllthomas on Wednesday June 25, 2014 @05:13PM
(#7946798)
Yes! Also, ^R^W (ctrl-r, ctrl-w) when you're at the : prompt will drop in the current word under the cursor. Which is also quite useful in keybindings.
[ Parent
| on HN ]
Thanks. That's a great tip. I've always yanked the word that I wanted and then used Ctrl-R" to paste it on Vim's command line. This is much better.
I'm now off to read "cmdline.txt" (:help Command-line).
BTW, I just accidentally closed my browser tab (latest version of Firefox) by hitting Ctrl-W when I wanted to delete the previous word in this textbox. That used to drive me mad but when Firefox restored the tab, it also restored the text I'd typed. :)