Configuration file for vim under Windows _VIMRC

Source: Internet
Author: User
Tags diff

Set Nocompatiblesource $VIMRUNTIME/Vimrc_example.vimsource $VIMRUNTIME/mswin.vimbehave mswinset nobackupset noundofileset noswapfileset encoding=utf-8Set Fileencodings=utf-8, chinese,latin-1ifHas ("Win32") Set fileencoding=ChineseElseSet fileencoding=utf-8endif"Fix Menu garbledSOURCE $VIMRUNTIME/Delmenu.vimsource $VIMRUNTIME/Menu.vim"solve Consle output garbledLanguage Messages zh_cn.utf-8Set diffexpr=Mydiff ()functionMydiff () let opt='-A --binary'  if&diffopt =~'icase'| Let opt = opt.'- I.'|endifif&diffopt =~'Iwhite'| Let opt = opt.'- b'|endif let Arg1=v:fname_inifArg1 =~' '| Let arg1 ='"'. Arg1.'"'|endif let Arg2=v:fname_newifArg2 =~' '| Let arg2 ='"'. Arg2.'"'|endif let Arg3=V:fname_outifArg3 =~' '| Let Arg3 ='"'. Arg3.'"'|endifif$VIMRUNTIME =~' '    if&SH=~'\<cmd'      ifEmpty (&shellxquote) Let L:shxq_sav="'Set Shellxquote&endif let cmd='"'. $VIMRUNTIME.'\diff "'    ElseLet cmd= Substitute ($VIMRUNTIME,' ','" ',"') .'\diff "'endifElseLet cmd= $VIMRUNTIME.'\diff'endif Silent Execute'!'. Cmd.' '. Opt. Arg1.' '. Arg2.'>'. Arg3ifExists'L:shxq_sav') Let&shellxquote=L:shxq_sav endifendfunction"Set the status bar"Set laststatus=2"set statusline=[%f]%y%r%m%*%=[line:%l/%l,column:%c][%p%%]"Set title display contentLet &titlestring = expand ("%:p")if&term = =" Screen"Set T_ts=^[k Set T_fs=^[endifif&term = =" Screen"|| &term = ="xterm"Set Titleendif"If you put the expand in the above code ("%:p") Change to expand ("%:t"the path will not show only the file name. ColorScheme Desert

Configuration file for vim under Windows _VIMRC

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.