Last active
December 21, 2015 02:29
-
-
Save maxdeliso/6235530 to your computer and use it in GitHub Desktop.
.vimrc & .gitconfig
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[user] | |
email = [email protected] | |
name = Max DeLiso | |
[push] | |
default = matching | |
[core] | |
editor = gvim | |
[color] | |
ui = true | |
[alias] | |
graph = log --oneline --graph |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"" Max DeLiso .vimrc | |
"" various line editing settings | |
set sw=2 ts=2 sts=-1 et sr ff=unix nu tw=100 cc=+1 noswapfile background=dark | |
"" suffixes and manpages | |
syntax on | |
filetype plugin indent on | |
runtime ftplugin/man.vim | |
"" plugin management | |
execute pathogen#infect() | |
"" https://github.com/scrooloose/syntastic | |
"" https://github.com/tejr/sahara | |
colorscheme solarized | |
"" highlight trailing whitespace | |
highlight ExtraWhitespace ctermbg=red guibg=red | |
match ExtraWhitespace /\s\+$/ | |
autocmd BufWinEnter * match ExtraWhitespace /\s\+$/ | |
autocmd InsertEnter * match ExtraWhitespace /\s\+\%#\@<!$/ | |
autocmd InsertLeave * match ExtraWhitespace /\s\+$/ | |
autocmd BufWinLeave * call clearmatches() | |
"" remove trailing whitespace on save | |
autocmd FileType c,cpp,py,rb,scala,clj,hs autocmd BufWritePre <buffer> :%s/\s\+$//e | |
"" https://github.com/bitc/vim-hdevtools | |
au FileType haskell nnoremap <buffer> <F1> :HdevtoolsType<CR> | |
au FileType haskell nnoremap <buffer> <silent> <F2> :HdevtoolsClear<CR> | |
"" suppress file has changed messages, git makes them redundant | |
function! ProcessFileChangedShell() | |
if v:fcs_reason == 'mode' || v:fcs_reason == 'time' | |
let v:fcs_choice = '' | |
else | |
let v:fcs_choice = 'ask' | |
endif | |
endfunction | |
autocmd FileChangedShell <buffer> call ProcessFileChangedShell() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment