.vimrc.orig 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. " Pathogen must be loaded first
  2. execute pathogen#infect()
  3. syntax on
  4. filetype on
  5. filetype indent plugin on
  6. set modeline
  7. set tabstop=2 shiftwidth=2 expandtab
  8. " use flake8 to ensure PEP-8 compliance for python
  9. source ~/.vim/bundle/flake8/ftplugin/python_flake8.vim
  10. let g:flake8_builtins="_,apply"
  11. autocmd FileType python map <buffer> <F3> :call Flake8()<CR>
  12. set background=light
  13. set showcmd
  14. " highlight searches
  15. set hlsearch
  16. " case insensitive searches
  17. set incsearch
  18. " Relative line numbers except the current line
  19. " Both relativenumber with number works on vim 7.4+
  20. "set relativenumber
  21. "set number
  22. let g:solarized_termcolors=256
  23. colorscheme solarized
  24. " Highlight 80 column
  25. set colorcolumn=80
  26. highlight ColorColumn ctermbg=223
  27. " Jump to last position in file when reopening
  28. if has("autocmd")
  29. au BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g'\"" | endif
  30. endif
  31. " Switch between light/dark backgrounds
  32. " F12 toggles between light and dark backgrounds
  33. map <silent> <F12> :if &background == "light"<CR>
  34. \set background=dark<CR>
  35. \else<CR>
  36. \set background=light<CR>
  37. \endif<CR>
  38. set t_Co=256
  39. " always show vim-airline
  40. set laststatus=2
  41. let g:airline#extensions#branch#format = 1
  42. if !exists('g:airline_symbols')
  43. let g:airline_symbols = {}
  44. endif
  45. " unicode symbols
  46. let g:airline_left_sep = '»'
  47. let g:airline_left_sep = '▶'
  48. let g:airline_right_sep = '«'
  49. let g:airline_right_sep = '◀'
  50. let g:airline_symbols.crypt = '🔒'
  51. let g:airline_symbols.linenr = '␊'
  52. let g:airline_symbols.linenr = '␤'
  53. let g:airline_symbols.linenr = '¶'
  54. let g:airline_symbols.maxlinenr = '☰'
  55. let g:airline_symbols.maxlinenr = ''
  56. let g:airline_symbols.branch = '⎇'
  57. let g:airline_symbols.paste = 'ρ'
  58. let g:airline_symbols.paste = 'Þ'
  59. let g:airline_symbols.paste = '∥'
  60. let g:airline_symbols.spell = 'Ꞩ'
  61. let g:airline_symbols.notexists = '∄'
  62. let g:airline_symbols.whitespace = 'Ξ'
  63. " Fix intendation
  64. map <F5> mzgg=G`z<CR>
  65. " editorconfig should not tamper with fugitive
  66. let g:EditorConfig_exclude_patterns = ['fugitive://.*']