My dotfiles. Period.

vimrc 2.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. " ....... "
  2. " PLUGINS "
  3. " ''''''' "
  4. execute pathogen#infect()
  5. let g:local_vimrc=".vimrc_local.vim"
  6. let python_highlight_all = 1
  7. let g:vim_markdown_folding_disabled=1
  8. let g:swap_custom_ops = ['and', 'or']
  9. nmap <F6> :SyntasticCheck<CR>
  10. set statusline+=%#warningmsg#
  11. set statusline+=%{SyntasticStatuslineFlag()}
  12. set statusline+=%*
  13. let g:syntastic_always_populate_loc_list = 1
  14. let g:syntastic_auto_loc_list = 0
  15. let g:syntastic_check_on_open = 0
  16. let g:syntastic_check_on_wq = 0
  17. let g:syntastic_mode_map = {
  18. \ "mode": "active",
  19. \ "active_filetypes": ["bash"],
  20. \ "passive_filetypes": ["python"] }
  21. " ..................... "
  22. " PROGRAM / ENVIRONMENT "
  23. " ''''''''''''''''''''' "
  24. set clipboard=unnamed
  25. set encoding=utf-8
  26. set fileencodings=ucs-bom,utf-8,cp1250,latin1
  27. set history=500
  28. " swap settings "
  29. if isdirectory($HOME . '/.local/share/vim') == 0
  30. :silent !mkdir -p ~/.vim/swap >/dev/null 2>&1
  31. endif
  32. set directory=./.vim-swap//
  33. set directory+=~/.local/share/vim/swap//
  34. set directory+=~/tmp//
  35. set directory+=.
  36. " ............ "
  37. " UI - GENERAL "
  38. " '''''''''''' "
  39. set t_vb=
  40. noremap <F2> :set list!<CR>
  41. set pastetoggle=<F4>
  42. nmap <F3> :set invnumber<CR>
  43. if has('mouse')
  44. set mouse=a
  45. endif
  46. if !exists(":DiffOrig")
  47. command DiffOrig vert new
  48. \ | set bt=nofile
  49. \ | r ++edit #
  50. \ | 0d_
  51. \ | diffthis
  52. \ | wincmd p
  53. \ | diffthis
  54. endif
  55. " ............ "
  56. " UI - EDITING "
  57. " '''''''''''' "
  58. set autoindent
  59. set backspace=indent,eol,start
  60. set expandtab
  61. set incsearch
  62. set shiftwidth=4
  63. set tabstop=4
  64. inoremap <C-Left> <C-P>
  65. inoremap <C-Right> <C-N>
  66. noremap p p`[
  67. noremap P P`[
  68. if has("autocmd")
  69. filetype plugin indent on
  70. augroup vimrcEx
  71. au!
  72. autocmd FileType text setlocal textwidth=78
  73. autocmd BufNewFile,BufReadPost *.md set filetype=markdown
  74. autocmd BufNewFile,BufReadPost *TESTOUT.log* set filetype=beakerlib
  75. autocmd BufReadPost *
  76. \ if line("'\"") > 1 && line("'\"") <= line("$") |
  77. \ exe "normal! g`\"" |
  78. \ endif
  79. augroup END
  80. else
  81. set autoindent
  82. endif
  83. " .......... "
  84. " UI - LOOKS "
  85. " '''''''''' "
  86. set list
  87. set list listchars=tab:→\ ,trail:·,precedes:←
  88. set ruler
  89. set showcmd
  90. set nowrap
  91. if &t_Co > 2 || has("gui_running")
  92. syntax on
  93. set hlsearch
  94. endif
  95. colorscheme delek
  96. hi Folded ctermbg=NONE
  97. "set gfn=Droid\ Sans\ Mono\ 9
  98. set number
  99. highlight LineNr term=bold cterm=NONE ctermfg=DarkGrey ctermbg=NONE gui=NONE guifg=DarkGrey guibg=NONE
  100. highlight MatchParen cterm=bold ctermfg=NONE ctermbg=black
  101. highlight Search term=NONE cterm=NONE ctermfg=NONE ctermbg=235 "DarkGreen
  102. if &term =~ "xterm\\|rxvt"
  103. silent !echo -ne "\033]12;gray75\007"
  104. let &t_SI = "\<Esc>]12;gray25\x7"
  105. let &t_EI = "\<Esc>]12;gray75\x7"
  106. autocmd VimLeave * let &t_me="\<Esc>]12;white\x7"
  107. endif