Dive into VIM, part 1
I used to think that I have already mastered VIM. But I was wrong...
This is what I have learned today:
Repeat actions for selected lines
VG to select lines
:normal to apply . to each line that you selected
Search and Replacement of current word
* to search current word
caw to delete current word and get into insert mode, c means change (caw: change a word)
n. to replace the next matched word
Word deletion
daw: delete a word
dap: delete a paragraph
d2w: delete 2 words
c2w: delete 2 words and get into insert mode
Word case change
vaw~: visualize a word, and change its case.
Quick mode change
in the insert mode: ctrl+w will delete a word before your cursor
back to normal mode: ctrl+[
Copy and paste for a word
vawy: visualize a word and copy it
vawp: visualize a word and replace it with copied text
Get help:help operator will pop up the help document