" File: _vimrc
" Author: xuleaper<xuleaper@gmail.com>
" Description: xuleaper's personal vim config file.
" Last Modified: $Id: _vimrc 467 2012-09-08 03:49:05Z $
" Blog: http://www.gracecode.com/
" Since:2010-06-15
" History:
" 2012-06-08
" +vundle支持,更加灵活的管理插件
" 2012-01-20
" +整理vimrc结构
" 2011-09-08
" +在网络配置文件的基础上,编写自己的vimrc
"=============================
" vimrc_structure
" |
" +--Environment setting
" |
" +--Multi_language setting
" |
" +--GUI_laguage setting
" |
" +--AutoCmd
" |
" +--Plugin configure
" |
" +--Script's function
" |
" +--Key shortcut
" |
" ---Bundle setting
"=============================
if exists("mingcheng")
finish
endif
let g:mingcheng = 1
if v:version < 700
echoerr 'This _vimrc requires Vim 7 or later.'
quit
endif
" ============
" Environment
" ============
" Color Scheme
if has('syntax')
colorscheme zenburn
" 默认编辑器配色
au BufNewFile,BufRead,BufEnter,WinEnter * colo desert
" 各不同类型的文件配色不同
au BufNewFile,BufRead,BufEnter,WinEnter *.wiki colo void
" 保证语法高亮
syntax on
endif
" 保留历史记录
set history=500
" 行控制
set linebreak
set nocompatible
set textwidth=80
set wrap
" 标签页
set tabpagemax=9
set showtabline=2
" 控制台响铃
set noerrorbells
set novisualbell
set t_vb=
" 行号和标尺
set number
set ruler
set rulerformat=%15(%c%V\ %p%%%)
" 命令行于状态行
set ch=2
set stl=\ [File]\ %F%m%r%h%y[%{&fileformat},%{&fileencoding}]\ %w\ \ [PWD]\ %r%{GetPWD()}%h\ %=\ [Line]%l/%L\ %=\[%P]
set ls=2 " 始终显示状态行
set wildmenu "命令行补全以增强模式运行
" 定义 <Leader> 为逗号
let mapleader = ","
let maplocalleader = ","
" Search Option
set hlsearch " Highlight search things
set magic " Set magic on, for regular expressions
set showmatch " Show matching bracets when text indicator