I flip between ex commands and macros for semi-automated file
conversion and most of what I'd say has been covered, but I'll toss in
a personal quirk from my .vimrc.

By default, both ` and ' do approximately the same thing in that they
jump to a mark (' is a linewise `, it positions the cursor at ^ in the
destination line). Since I don't find ' to be particularly useful, I
remap it to @a and record my macros to "a (qa...q):

 "executes the macro in register a
 nnoremap ' @a

 "repeats the macro in register a for the entire visual selection
 xnoremap ' :normal @a<CR>

I find this to be convenient and it provided an easy way to
record/execute macros when I was learning vim.

Reply via email to