"============================================================================= " .gvimrc " Andreas Kühntopf (andreas@kuehntopf.org) " 0.2 " http://kuehntopf.org "============================================================================= "============================================================================= " General "============================================================================= set nocompatible " Vi-incompatible behavior set visualbell " Don't beep, flash screen on errors colorscheme koehler " Put your favorite here syntax on " Always have syntax highlighting set ai " Auto Indent set si " Smart Indent set ic " Ignore case when searching set expandtab " Expand tabs to whitespaces set tabstop=4 " 1 Tabstop = 4 Whitespaces set shiftwidth=4 " 4 Whitespaces indentation set softtabstop=4 " 4 Whitespaces for text operations (backspace etc) "============================================================================= " GUI options "============================================================================= set guioptions-=T " No Toolbar "============================================================================= " Custom functions "============================================================================= " Function to insert a file from ~/.vim directory " (like templates, licenses, etc...) " function! IncludeFile(fn) let filename = $HOME . "/" . ".vim" . "/" . a:fn execute ":0r " . filename endfunction " Sample command command Insertgpl call IncludeFile("gpl.txt") "============================================================================= " Key mappings "============================================================================= map :w:make " F1 does a save & make map :cn " F2 jumps to next error map :cp " Shift-F2 jumps to prev error imap :w:makei " Same imap :cn " Mappings for imap :cp " Edit mode map :e %:p:h " Open NetRW in current directory " Toggle Mode with C-Enter imap nmap i "============================================================================= " Script settings "============================================================================= " EnhancedCommentify let g:EnhCommentifyRespectIndent = 'Yes' let g:EnhCommentifyPretty = 'Yes' let g:EnhCommentifyMultiPartBlocks = 'yes'