Re:Programs that have saved me 100+ hours
by fiddlerwoaroof on Thursday March 16, 2017 @05:39PM
(#13889445)
It's worth remembering that . (i.e. dot) repeats the last edit command. vim-repeat ( https://github.com/tpope/vim-repeat ) makes this even better.
Although, there are still several situations where macros are better, especially things that involve several motions and edits. (I tend to use qw because w is more convenient to hit after @).
Also, it's occasionally useful to remember that you can use the double quote character " to paste a macro, edit it and then update it. i.e. ( "ep .... edit ... ^"ed$ )
Re:Programs that have saved me 100+ hours
by fiddlerwoaroof on Thursday March 16, 2017 @05:41PM
(#13889459)
Also, vim-surround is one of those things that, once you've used it for a while, it's impossible to think of editing text without it: https://github.com/tpope/vim-surround
Re:Programs that have saved me 100+ hours
by dasil003 on Thursday March 16, 2017 @06:47PM
(#13889853)
Any vim user can profit from visiting https://github.com/tpope?q=vim&tab=repositories and trying any one that looks vaguely interesting.
Compared to regex search and replace this is much more malleable, interactive, and ultimately powerful.