syntax enable
set nocompatible
set tabstop=2
set shiftwidth=2
set softtabstop=2
set backspace=2
set expandtab
set vb t_vb=
set fo-=r
set nu
set hlsearch
set incsearch
set ruler
set autochdir
set autoread
set showcmd
set sm
set tags=tags;
set noerrorbells
set novisualbell
set magic
set nolazyredraw
"if MySys() == "windows"
" set encoding=cp936
" set nobackup
" set nowritebackup
"elseif MySys() == "linux"
set encoding=utf-8
"endif
set fileencodings=ucs-bom,utf-8,cp936,gb18030,big5,euc-jp,euc-kr,latin1
set fileencoding=utf-8
map j
map k
map h
map l
colorscheme zellner
"for .gvimrc
if has("gui_running")
set lines=40
set columns=90
highlight Normal guibg=#f0f8ff
"if MySys() == "windows"
" set guifont=Consolas:h15
"elseif MySys() == "linux"
set guifont=Bitstream\ Vera\ Sans\ Mono\ 10
"set guifont=VL\ gothic\ 11
"endif
endif
set undodir=~/.vim/undodir
set undofile
set undolevels=1000
set undoreload=10000
filetype on
nnoremap :TlistToggle
let Tlist_Exit_OnlyWindow=1
" set cscopequickfix=s-,c-,d-,i-,t-,e-
" cscope -Rbq
"""""""""""""""""""""""""""""""""
以下补充一些可能vim中有用的命令
:%!xxd 按十六进制查看当前文件
:%!xxd -r 从十六进制返回正常模式
新发现:
nmap :w:!indent..... %:!ctags -R .:e
阅读(831) | 评论(0) | 转发(0) |