" No, it is not VI, it is VIM! Set this first, it is important. " It is important to set this first, because this command reset many " other options. set nocompatible " * Generic / Interface set mouse=a " klicki-bunti[tm] " syntax hilighting syntax on " color setting colorscheme koehler " Do not visually wrap long lines - do not make it look like there are line " breaks where there aren't " set nowrap set showbreak=+ " prefix wrapped lines with a + sign " The minimal number of columns to scroll horizontally set sidescroll=1 " use folds: {{{ ... }}} set foldmethod=marker " show line numbers " set number " show matching braces set showmatch " intendion settings " set shiftwidth=3 " set tabstop=3 " when inserting TABs replace them with the appropriate number of spaces " set expandtab " TABs are needed in Makefiles au BufNewFile,BufReadPost Makefile se noexpandtab " C-style comment-in and comment-out map ,q 0i/* A */j map ,Q 0xxx$xxxj " make searches case-insensitive, unless they contain upper-case letters: set ignorecase set smartcase " When searching for a long(ish) expression with / (or ?), its often only " necessary to enter the first few characters. The trouble is knowing how many. " incsearch searches immediately as each character is typed. set incsearch " toggle the hilight search with map :set hls!set hls? " assume the /g flag on :s substitutions to replace all matches in a line: " set gdefault " always show the name of the file being edited set ls=2 " always show commands that are not yet typed in completely set showcmd " split window min size set winminheight=0 " * Keystrokes -- Moving Around " scroll the window (but leaving the cursor in the same place) by a couple of " lines up/down with / (like in `Lynx'): " noremap 2 " noremap 2 " [ by default is like i, and like x.] " use to cycle through split windows (and + to cycle backwards, " where possible): nnoremap w nnoremap W " use +N/+P to cycle through files: nnoremap :next nnoremap :prev " [+N by default is like j, and +P like k.] " VIM tip #80 " Author: Charles E Campbell " When editing a file, always jump to the last cursor position (if saved) au BufReadPost * if line("'\"") > 0 | \ if line("'\"") <= line("$") | \ exe "norm `\"" | \ else | \ exe "norm $" | \ endif | \ endif " toggle paste-mode map :set paste map :set nopaste imap :set paste imap set pastetoggle= " miniBufExpl plugin settings let g:miniBufExplMapWindowNavVim = 1 let g:miniBufExplMapWindowNavArrows = 1 let g:miniBufExplMapCTabSwitchBufs = 1 let g:miniBufExplModSelTarget = 1 let g:miniBufExplorerMoreThanOne=3