Created
March 30, 2011 04:34
-
-
Save auxesis/893870 to your computer and use it in GitHub Desktop.
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
| " sessions, backups, temporary files | |
| set backup " Enable creation of backup file. | |
| set backupdir=~/.vim/backups " Where backups will go. | |
| set directory=~/.vim/tmp " Where temporary files will go. | |
| set viminfo='100,f1 | |
| " how long key sequences can take to complete | |
| set timeoutlen=250 | |
| " color schemes | |
| set t_Co=256 | |
| set background=dark | |
| "colorscheme eve | |
| " display | |
| set nowrap | |
| set number | |
| syntax on | |
| " highlight the current line | |
| "se cursorline | |
| hi CursorLine term=none cterm=none ctermbg=1 | |
| " searching behavior | |
| set ignorecase | |
| set smartcase | |
| set incsearch | |
| "set shiftround | |
| "set smarttab | |
| "set expandtab | |
| "set sts=0 | |
| set autoindent | |
| set smartindent | |
| set ts=2 | |
| set sw=2 | |
| "set guioptions+=T | |
| set statusline=%F%m%r%h%w\ [POS=%04l,%04v]\ [FORMAT=%{&ff}]\ [TYPE=%Y]\ [LEN=%L] | |
| set laststatus=2 | |
| " http://vim.wikia.com/wiki/Remove_unwanted_spaces | |
| " | |
| " Removes trailing spaces | |
| function TrimWhiteSpace() | |
| %s/\s*$// | |
| '' | |
| :endfunction | |
| au FileWritePre * :call TrimWhiteSpace() | |
| au FileAppendPre * :call TrimWhiteSpace() | |
| au FilterWritePre * :call TrimWhiteSpace() | |
| au BufWritePre * :call TrimWhiteSpace() | |
| set listchars=tab:>-,trail:. " Display unwanted whitespace | |
| set list | |
| filetype on | |
| filetype plugin on | |
| filetype indent on | |
| " keybindings | |
| "let g:SuperTabDefaultCompletionType = "<C-X><C-O>" | |
| "map ESC:vsplit | |
| " filetypes | |
| au BufRead,BufNewFile *.pp set filetype=puppet | |
| au BufRead,BufNewFile *.haml set filetype=haml | |
| au BufRead,BufNewFile *.scala set filetype=scala | |
| au BufRead,BufNewFile *.feature set filetype=cucumber | |
| au BufRead,BufNewFile *.md set filetype=markdown | |
| au BufRead,BufNewFile *.erb set filetype=eruby | |
| au BufRead,BufNewFile *.thor set filetype=ruby | |
| au BufRead,BufNewFile *.ru set filetype=ruby | |
| au BufRead,BufNewFile *.markdown set filetype=markdown | |
| au BufRead,BufNewFile COMMIT_EDITMSG set expandtab | |
| au FileType python set ts=4 sw=4 tw=100 sts=4 | |
| au FileType ruby set ts=2 sw=2 tw=100 sts=2 expandtab | |
| au FileType javascript set ts=4 sw=4 tw=100 sts=4 expandtab | |
| "au FileType ruby set ts=2 sw=2 tw=100 sts=2 | |
| au FileType html set ts=2 sw=2 tw=100 sts=2 expandtab | |
| au FileType eruby set ts=2 sw=2 expandtab | |
| au FileType haml set ts=2 sw=2 expandtab | |
| "au FileType markdown set expandtab | |
| au FileType css set expandtab | |
| au FileType cucumber set ts=2 sw=2 expandtab | |
| au FileType markdown set ai formatoptions=tcroqn2 comments=n:> expandtab | |
| au FileType puppet set expandtab | |
| " shortcuts | |
| map c :silent execute "!nanoc3 co &>/dev/null &" | redraw! | |
| map cj :silent execute "!jekyll &>/dev/null &" | redraw! | |
| "map p :set wrap linebreak nolist columns=100 | |
| command! -nargs=* Writing set wrap linebreak nolist nonu columns=80 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment