Re: Vim: deleting first character and inserting a char at first column
- From: Ivan Harden <ivan.harden@xxxxxxxxx>
- Date: Thu, 10 Apr 2008 02:41:36 +0200
On 10 Apr 2008 00:01:29 GMT, Gary Johnson <garyjohn@xxxxxxxxxx> wrote:
The way I do this depends on the number of lines I'm changing and
whether the changes are to contiguous lines. The simplest method is to
move the cursor to the first line, type
I
followed by the character or characters to be inserted, followed by
typing the Esc key. To repeat the insertion on subsequent lines, I type
Enter to move to the next line, then
.
to repeat the last change. Then I just put my ring finger on the Enter key,
my index finger on the . and alternate the two until the "marking" is
done. To skip a line, I just hit Enter an extra time without hitting
the ..
Hi Gary, thanks for answering.
I'm familiar with the above procedure, since it's the one I'm using
and trying to avoid.
The main problem with it is that you repeat the last command with .
If you do something in between (like moving a lot of lines up and
down, and setting some numeric values in them) then it becomes
tiresome quickly.
The bottom one is pretty much the same, except it includes the use of
V mode.
I'm currently in the process of help reading, and trying to do patch
up something like this:
- read some string
- put it out
<c-r>=strftime("%a %d %b %Y")<cr>
(in an analogous manner)
- map some key to do it quickly
You wouldn't know by any chance how to read a string and how to put it
out ?
Ivan
.
- Follow-Ups:
- Re: Vim: deleting first character and inserting a char at first column
- From: Gary Johnson
- Re: Vim: deleting first character and inserting a char at first column
- References:
- Vim: deleting first character and inserting a char at first column
- From: Ivan Harden
- Re: Vim: deleting first character and inserting a char at first column
- From: Gary Johnson
- Vim: deleting first character and inserting a char at first column
- Prev by Date: Re: Vim: deleting first character and inserting a char at first column
- Next by Date: Re: Vim: deleting first character and inserting a char at first column
- Previous by thread: Re: Vim: deleting first character and inserting a char at first column
- Next by thread: Re: Vim: deleting first character and inserting a char at first column
- Index(es):
Relevant Pages
|