vim配置

set number

set shortmess=atl

set autoindent

set cindent

set tabstop=4

set softtabstop=4

set shiftwidth=4

:inoremap ( ()i

:inoremap ) =ClosePair(')')

:inoremap { {}O

:inoremap } =ClosePair('}')

:inoremap [ []i

:inoremap ] =ClosePair(']')

:inoremap " ""i

:inoremap ' ''i

function! ClosePair(char)

if getline('.')[col('.') - 1] == a:char

return "\"

else

return a:char

endif

endfunction

filetype plugin indent on

set nobackup

set nowb

你可能感兴趣的:(vim配置)