随笔 - 64  文章 - 9  trackbacks - 0
<2010年5月>
2526272829301
2345678
9101112131415
16171819202122
23242526272829
303112345

常用链接

留言簿(6)

我参与的团队

随笔分类(88)

随笔档案(92)

文章分类(142)

文章档案(182)

天基成员

学习园

我的海角

搜索

  •  

积分与排名

  • 积分 - 178742
  • 排名 - 320

最新评论

Windows下vi的文件配置 

主页:http://www.vim.org
vim是linux下一款强大的编辑器,它以其强大的可定制性被广大Code Fans所追捧。
下载vim:
http://www.vim.org/download.php#pc(windows版本)
或者直接点击这里 ftp://ftp.vim.org/pub/vim/pc/gvim72.exe
下载–>安装
找到安装目录
如我的是D:"Program Files"Vim
我们会看到有一个 _vimrc 的文件,所有的配置文件都在这里
这里我给大家分享一下我这只小鸟的vim配置文件
就多加了几句:
就是 显示行号、最大化UI窗口、默认背景配置、去掉所有选项卡。
set nocompatible
set nu
source $VIMRUNTIME/vimrc_example.vim
source $VIMRUNTIME/mswin.vim
behave mswin
if has(“gui_running”)
set guioptions=
colorscheme darkZ
set cursorline
if has(“win32″)
set gfn=Raize
au GUIEnter * simalt ~x
else
set guifont=Raize" 13
set guifontwide=weiruanyahei" Bitmap" Song" 12
endif
else
colorscheme default
endif
set diffexpr=MyDiff()
function MyDiff()
let opt = ‘-a –binary ‘
if &diffopt =~ ‘icase’ | let opt = opt . ‘-i ‘ | endif
if &diffopt =~ ‘iwhite’ | let opt = opt . ‘-b ‘ | endif
let arg1 = v:fname_in
if arg1 =~ ‘ ‘ | let arg1 = ‘”‘ . arg1 . ‘”‘ | endif
let arg2 = v:fname_new
if arg2 =~ ‘ ‘ | let arg2 = ‘”‘ . arg2 . ‘”‘ | endif
let arg3 = v:fname_out
if arg3 =~ ‘ ‘ | let arg3 = ‘”‘ . arg3 . ‘”‘ | endif
let eq = ”
if $VIMRUNTIME =~ ‘ ‘
if &sh =~ ‘"<cmd’
let cmd = ‘”"‘ . $VIMRUNTIME . ‘"diff”‘
let eq = ‘”‘
else
let cmd = substitute($VIMRUNTIME, ‘ ‘, ‘” ‘, ”) . ‘"diff”‘
endif
else
let cmd = $VIMRUNTIME . ‘"diff’
endif
silent execute ‘!’ . cmd . ‘ ‘ . opt . arg1 . ‘ ‘ . arg2 . ‘ > ‘ . arg3 . eq
endfunction
黑体字是添加的,读者可自行添加。
另外 vim可以下载很多插件,http://www.vim.org/scripts/index.php
posted on 2010-05-04 12:35 鹏凌 阅读(436) 评论(0)  编辑  收藏 所属分类: Software_Recommend

只有注册用户登录后才能发表评论。


网站导航: