October 2012
346 pages
7h 40m
English
| Tip 1 | Meet the Dot Command |
The dot command lets us repeat the last change. It is the most powerful and versatile command in Vim.
Vim’s documentation simply states that the dot command “repeats the last change” (see .
). It doesn’t sound like much, but in that simple definition we’ll find the kernel of what makes Vim’s modal editing model so effective. First we have to ask, “What is a change?”
To understand the power of the dot command, we have to realize that the “last change” could be one of many things. A change could act at the level of individual characters, entire lines, or even the whole file.
To demonstrate, we’ll use this snippet ...
Read now
Unlock full access