Vim Environment parameter Configuration DIY

Source: Internet
Author: User

    • 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

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.