Skip to content

Instantly share code, notes, and snippets.

@aero
Created April 21, 2010 13:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aero/373793 to your computer and use it in GitHub Desktop.
Save aero/373793 to your computer and use it in GitHub Desktop.
set nocompatible
source $VIMRUNTIME/vimrc_example.vim
"source $VIMRUNTIME/mswin.vim
"behave mswin
"------------------ my config start ------------------
syntax on
set fencs=ucs-bom,utf-8,cp949
"매치하는 괄호를 보여준다.
set showmatch
set nobackup
colorscheme darkblue
"하나의 탭을 몇칸으로 할 것인가?
set ts=8
"TAB키를 눌렀을때 몇칸을 이동할 것인가?
set sts=4
"<<,>>를 눌렀을때 몇칸을 이동할 것인가?
set sw=4
"아래는 set backspace=indent,eol,start 와 같다.
set bs=2
"TAB을 모두 space로 대체한다.
set expandtab
if has('gui')
set guifont=Dina:h10
set columns=120
set lines=40
endif
"set for Hangul IME
"inoremap <ESC> <ESC>:set imdisable<CR>
"nnoremap i :set noimd<CR>i
"nnoremap I :set noimd<CR>I
"nnoremap a :set noimd<cr>a
"nnoremap A :set noimd<CR>A
"nnoremap o :set noimd<CR>o
"nnoremap O :set noimd<CR>O
if has('multi_byte_ime')
highlight CursorIM guibg=green guifg=NONE
endif
"Configuration for taglist plugin
"taglist http://www.vim.org/scripts/script.php?script_id=273
filetype on
let Tlist_Ctags_Cmd = 'C:\UnxUtils\usr\local\wbin\ctags.exe'
let Tlist_Display_Prototype = 1
let Tlist_Inc_WinWidth = 0
map <F3> :Tlist<CR>
"Configuration for winmanager
"winmanager http://www.vim.org/scripts/script.php?script_id=95
"bufexplorer http://www.vim.org/scripts/script.php?script_id=42
map <F2> :WMToggle<CR>
set statusline=%F%F%m%r%h%w\ [FORMAT=%{&ff}]\ [ENC,FENC=%{&enc},%{&fenc}]\ [TYPE=%Y]\ [ASCII=\%03.3b]\ [HEX=\%02.2B]\ [POS=%04l,%04v][%p%%]\ [LEN=%L]
set laststatus=2
"------------------ my config end ------------------
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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment