error when vim macro recording play -


i know how record macro use vim. eg. record macro a: in normal mode, qa start recording, action, q stop recording.


if want play it, can use @a. want play 10 times, 10@a should work, me, isn't work, play in 1 line.

why? should 10@a work?


just follow:

include <stdio.h> include <string.h> include <stdlib.h> include <unistd.h> include <my.h> 

i want add "#" @ every line, recode macro in first line, go down second line, action 4@a. wrong

#include <stdio.h> ####include <string.h> include <stdlib.h> include <unistd.h> include <my.h> 

you should include movement command (probably j in case) in macro. record macro as

qai#escjq

and play 4@a.


Comments

Popular posts from this blog

angularjs - ADAL JS Angular- WebAPI add a new role claim to the token -

php - CakePHP HttpSockets send array of paramms -

node.js - Using Node without global install -