More efficient use.
Select full text
Ggvg
File Header: GG, end: G
Redo:
CTRL + R
Fold code/Open fold:
ZF for folding
Zo, turn on and fold ZC, and turn off the fold
Jump to matching {or:
%
Mark the current word: # Or *
Jump to the next place: n (# marked forward, * marked backward)
Shift + N (opposite to N)
GENERAL: # mark, Shift + N next place.
Tag, compared to the/Buf search,/Buf will match the Buf content such as buffer by N. By marking with #, only the Buf words are matched.
Ctags Plugin:
1. Generate the tags file: ctags-r-c ++-kinds = + px-fields = + IAS-extra = + q
2. Jump to function, variable definition, declaration location: Ctrl +] (local variables do not generate tags)
Cross-file jump, G Ctrl +]
3. Return to the jump position: Ctrl + O/T
4. Open the function definition file and jump to the corresponding line: vim-T my_function
To solve this problem, you can only jump to the root directory of ctags. If the subdirectory prompts that the tags file cannot be found:
Edit ~ /. Vimrc, add: Set tags = tags;
1. Batch convert windows line tail characters to Unix format (/R/N to/N)
Sed-I's/\ r // 'filename1 filename2...
Or
Find DIR/-name "*. *" | xargs sed-I's/\ r //'
Bash & vi