Commits

Anonymous committed 6551697

More tweaks to the vimrc

Comments (0)

Files changed (1)

+"
+" Ohhh it's customized.
+"
+
+let mapleader=","
 
 call pathogen#runtime_append_all_bundles()
 
     autocmd FileType make setlocal ts=8 sts=8 sw=8 noexpandtab
 endif
 
+""""""""""""""""""""""""""
 " Search settings
+""""""""""""""""""""""""""
 set laststatus=2
 set showmatch
 set incsearch
 
+"" Make searches case-sensitive only if they contain upper-case characters
+set ignorecase
+set smartcase
+
+" Keep more context when scrolling off the end of a buffer
+set scrolloff=3
+
+
+""""""""""""""""""""""""""
+" Sounds
+""""""""""""""""""""""""""
+" No sound on errors
+set noerrorbells
+set novisualbell
+set t_vb=
+set tm=500
+
+
+""""""""""""""""""""""""""
 " Miscellaneous Settings
+""""""""""""""""""""""""""
 set number " Show line numbers
 set showtabline=2 " always show tabs
+" Keep more context when scrolling off the end of a buffer
+set scrolloff=3
 
-"command! W :w
-
+" Remap write so I don't have to save the shift keystroke  
+nmap <leader>w :w<cr>
 
 """"""""""""""""""""""""""
 " Backup settings
 let NERDTreeIgnore=['\.pyc$', '\.pyo$', '\.orig$']
 
 
+"""""""""""""""""""""""
+" PyFlakes
+"""""""""""""""""""""""
+let g:pyflakes_use_quickfix = 0
+
+
+
 """""""
 " Stuff from GRB
 """"""""
 inoremap <tab> <c-r>=InsertTabWrapper()<cr>
 inoremap <s-tab> <c-n>
 
+" Only do this part when compiled with support for autocommands.
+if has("autocmd")
+  " Enable file type detection.
+  " Use the default filetype settings, so that mail gets 'tw' set to 72,
+  " 'cindent' is on in C files, etc.
+  " Also load indent files, to automatically do language-dependent indenting.
+  filetype plugin indent on
 
+  " Put these in an autocmd group, so that we can delete them easily.
+  augroup vimrcEx
+  au!
+
+  " For all text files set 'textwidth' to 78 characters.
+  autocmd FileType text setlocal textwidth=78
+
+  " When editing a file, always jump to the last known cursor position.
+  " Don't do it when the position is invalid or when inside an event handler
+  " (happens when dropping a file on gvim).
+  autocmd BufReadPost *
+    \ if line("'\"") > 0 && line("'\"") <= line("$") |
+    \   exe "normal g`\"" |
+    \ endif
+
+  augroup END
+
+else
+
+  set autoindent		" always set autoindenting on
+
+endif " has("autocmd")
+
+
+
+" Set our shell to bash
+set shell=bash
+
+" Can't be bothered to understand the difference between ESC and <c-c> in
+" insert mode.... coming from emacs
+imap <c-c> <esc>
+
+" Helpful (yet rarely used)
+command! InsertTime :normal a<c-r>=strftime('%F %H:%M:%S.0 %z')<cr>
+