3 ms·
this is somewhat shorter: qq0i"<Esc>A",<Esc>jq@@ i agree this example is silly. i'd do something like :%s/.*/"&",/
by contras1970 7y ago
this is somewhat shorter:
qq0i"<Esc>A",<Esc>jq@@
i agree this example is silly. i'd do something like
:%s/.*/"&",/
- jnurmine 7y agoYeah, it is a toy example on purpose. Macros really shine when you need to do a bit more complex stuff, there is certainly a cutoff between ease of regex "from the top of my head" vs. spending time formulating it.