Every now and then I have to indent the lines in my script to 4 space characters.
I generally do it line by line.
Is there an automated command in vi using which I can indent some set of lines to desired number of space characters in one go.
Every now and then I have to indent the lines in my script to 4 space characters.
I generally do it line by line.
Is there an automated command in vi using which I can indent some set of lines to desired number of space characters in one go.
To indent the next five lines, you can use this command.
5>>
The number of characters to be used is set with the shift-width parameter. eg:
:set sw=4
Thanks, it worked.