Manual :
:syntax on
Script :
echo -e "syntax on" >> ~/.vimrc
ctrlp:
crtl + p # Search file more quickly
nerdtree:
Type :NERDTree # list file of folder , useless
multi-cscope-db :
ctrl + \ + g = search function definition
taglist :
Manual :
1. edit ~/.vimrc or ~/.vim/vimrc
nmap <silent> <F5> :TlistToggle<CR><C-W><C-W>
2. Type :TlistToggle
Script :
echo -e "nmap <silent> <F5> :TlistToggle<CR><C-W><C-W>" >> ~/.vimrc
supertab :
after install will work.
ex:
type pr + tab will appear lot of word to choose.
vim-easymotion :
Manual :
edit ~/.vimrc or ~/.vim/vimrc
let g:EasyMotion_leader_key = '\'
Script :
echo -e "let g:EasyMotion_leader_key = '\\'" >> ~/.vimrc
press \ + w will appear many word on the screen.
Choose one word which you want to move.
NERD Commenter:
,cc = Comment out the current line or text selected in visual mode.
,cu = Uncomments the selected line(s).
Reload all tabe
:bufdo e (cycle through all buffers in the buffer list)
:tabdo e
Reference :
How do you reload all vim windows at once?
Go to next tabe
gt
set ts=4 sw=4 et
vim undo file:
Manual :
" Undo file even quit vim {
set undofile
set undodir=/tmp
" }
Script :
echo -e "\" Undo file even quit vim {\n set undofile\n set undodir=/tmp\n \" }" >> ~/.vimrc
Discards any changes:
:edit! or :e!
Append string at the end of line
<Ctrl+v> (select range) --> $ (go the end of line) --> A ( Append the string at the end of line) --> Esc (Finish type)
Show Command historyq:
Reference :
- Vim 建議的四種 TAB 字元處理方式
- vim plugin 推薦 (For python and java )
- Undo all changes since opening buffer in vim
- 简明 Vim 练级攻略
- Using command-line history
0 意見:
張貼留言