My dotfiles. Period.

vimrc 2.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  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. " ..................... "
  10. " PROGRAM / ENVIRONMENT "
  11. " ''''''''''''''''''''' "
  12. set encoding=utf-8
  13. set fileencodings=ucs-bom,utf-8,cp1250,latin1
  14. set history=500
  15. if isdirectory($HOME . '/.local/share/vim') == 0
  16. :silent !mkdir -p ~/.vim/swap >/dev/null 2>&1
  17. endif
  18. set directory=./.vim-swap//
  19. set directory+=~/.local/share/vim/swap//
  20. set directory+=~/tmp//
  21. set directory+=.
  22. " ............ "
  23. " UI - GENERAL "
  24. " '''''''''''' "
  25. noremap <F2> :set list!<CR>
  26. set pastetoggle=<F4>
  27. nmap <F3> :set invnumber<CR>
  28. if has('mouse')
  29. set mouse=a
  30. endif
  31. if !exists(":DiffOrig")
  32. command DiffOrig vert new
  33. \ | set bt=nofile
  34. \ | r ++edit #
  35. \ | 0d_
  36. \ | diffthis
  37. \ | wincmd p
  38. \ | diffthis
  39. endif
  40. " ............ "
  41. " UI - EDITING "
  42. " '''''''''''' "
  43. set autoindent
  44. set backspace=indent,eol,start
  45. set expandtab
  46. set incsearch
  47. set shiftwidth=4
  48. set tabstop=4
  49. inoremap <C-Left> <C-P>
  50. inoremap <C-Right> <C-N>
  51. if has("autocmd")
  52. filetype plugin indent on
  53. augroup vimrcEx
  54. au!
  55. autocmd FileType text setlocal textwidth=78
  56. autocmd BufNewFile,BufReadPost *.md set filetype=markdown
  57. autocmd BufReadPost *
  58. \ if line("'\"") > 1 && line("'\"") <= line("$") |
  59. \ exe "normal! g`\"" |
  60. \ endif
  61. augroup END
  62. else
  63. set autoindent
  64. endif
  65. " .......... "
  66. " UI - LOOKS "
  67. " '''''''''' "
  68. set list
  69. set list listchars=tab:→\ ,trail:·,precedes:←
  70. set ruler
  71. set showcmd
  72. set nowrap
  73. if &t_Co > 2 || has("gui_running")
  74. syntax on
  75. set hlsearch
  76. endif
  77. colorscheme pablo
  78. hi Folded ctermbg=NONE
  79. "set gfn=Droid\ Sans\ Mono\ 9
  80. set number
  81. highlight LineNr term=bold cterm=NONE ctermfg=DarkGrey ctermbg=NONE gui=NONE guifg=DarkGrey guibg=NONE
  82. highlight MatchParen cterm=bold ctermfg=NONE ctermbg=black
  83. if &term =~ "xterm\\|rxvt"
  84. silent !echo -ne "\033]12;gray50\007"
  85. let &t_SI = "\<Esc>]12;gray75\x7"
  86. let &t_EI = "\<Esc>]12;gray50\x7"
  87. autocmd VimLeave * let &t_me="\<Esc>]12;white\x7"
  88. endif