- Refer to "Stupid methodology Vimscript" http://learnvimscriptthehardway.onefloweroneworld.com/
- System environment
Ubantu 12.04
- Start with the vim example from the Ubantu system. /usr/share/vim/vim**/vimrc_example.vim, copy the file to ~/.VIMRC
- Add DIY configuration options
Augroup Filetype_vim
autocmd!
Autocmd FileType vim setlocal foldmethod=marker
"Use the marker method of folding for any Vimscript files
"For Instance:z-a Open and close maker
Augroup END
"Basic setting--------{{{}}
Let Mapleader = ","
Let Maplocalleader = "."
"<LocalLeader> is-be-used for mappings which was local to a buffer.
"}}}
"Filetype-specific Settings----{{{
Autocmd FileType vim nnoremap <buffer> <localleader>c I "<esc>
"}}}
"Mappings setting---------{{{
echo ">^.^<"
Noremap-ddp
"Move a row down
Noremap _ DDKKP
"Move a row up
Nnoremap <leader>u Viwu
"Lowercase-Uppercase
Inoremap <leader>u <esc>viwui
Nnoremap <leader>d DD
Nnoremap <leader>ev:vsplit $MYVIMRC <cr>
Nnoremap <leader>sv:source $MYVIMRC <cr>
Inoremap JK <esc>
Inoremap <esc> <nop>
Noremap <left> <nop>
Noremap <right> <nop>
Noremap <up> <nop>
Noremap <down> <nop>
Noremap AK <c-u>
Noremap AJ <c-d>
"}}}
Vim Environment parameter Configuration DIY