" Brad's .vimrc - mostly copied from lamby :) set nocompatible " Formatting set tabstop=4 set softtabstop=4 set shiftwidth=4 set expandtab set cino= set showmatch set autoindent wildmenu number smartindent set showcmd set wrap autocmd FileType make set noexpandtab autocmd FileType asm set noexpandtab | set cindent autocmd FileType c set noexpandtab | set cindent autocmd FileType cpp set noexpandtab | set cindent autocmd FileType h set noexpandtab | set cindent " Some insert mode shortcuts inoremap me -- Bradley Smith :r! date -Ri inoremap cb /************************************************************************** * * * * **************************************************************************/ inoremap gpl /* Copyright (C) 2008 Bradley Smith * * $PROJECT * * $PROJECT is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * $PROJECT is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with $PROJECT. If not, see . */ " Kinda legay way of doing cursor movement wrt. wrap mode map g0 map g$ map k gk map j gj map gk map gj map :q map :%!indent -bli0 -i4 -npcs -npsl -ut -ts4 map :make!:cw inoremap inoremap " ctags map :TlistToggle map :TlistUpdate:TlistHighlightTag let Tlist_Use_Right_Window = 1 let Tlist_WinWidth = 40 let Tlist_Inc_Winwidth = 0 "let Tlist_Use_SingleClick = 1 let Tlist_Exit_OnlyWindow = 1 " Quick shortcut for a new buffer map :enew " Shiny syntax on colorscheme elflord set cmdheight=1 " Because I can't use a keyboard properly command -bang Q q command -bang W w command -bang Wq wq command -bang WQ wq " make searches case-insensitive, unless they contain upper-case letters set ignorecase set smartcase set incsearch set hlsearch " Don't litter the working dir with swapfiles set backupdir=.backup,/tmp,. set directory=.backup,/tmp,. highlight WhitespaceEOL ctermbg=red guibg=red match WhitespaceEOL /\s\+$/ filetype plugin on if has("gui_running") set gfn=Monospace\ 10 set guioptions-=T " no toolbar set lines=45 set columns=115 au VimEnter * set nonu au VimEnter * wincmd p colorscheme brad endif