Advertisement
Guest User

.vimrc

a guest
Sep 27th, 2018
210
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.08 KB | None | 0 0
  1. if v:lang =~ "utf8$" || v:lang =~ "UTF-8$"
  2. set fileencodings=ucs-bom,utf-8,latin1
  3. endif
  4.  
  5. set nocompatible " Use Vim defaults (much better!)
  6. set bs=indent,eol,start " allow backspacing over everything in insert mode
  7. "set ai " always set autoindenting on
  8. "set backup " keep a backup file
  9. set viminfo='20,\"50 " read/write a .viminfo file, don't store more
  10. " than 50 lines of registers
  11. set history=50 " keep 50 lines of command line history
  12. set ruler " show the cursor position all the time
  13.  
  14.  
  15. " Switch syntax highlighting on, when the terminal has colors
  16. " Also switch on highlighting the last used search pattern.
  17. if &t_Co > 2 || has("gui_running")
  18. syntax on
  19. set hlsearch
  20. endif
  21.  
  22. if &term=="xterm"
  23. set t_Co=8
  24. set t_Sb=[4%dm
  25. set t_Sf=[3%dm
  26. endif
  27.  
  28. " Don't wake up system with blinking cursor:
  29. " http://www.linuxpowertop.org/known.php
  30. let &guicursor = &guicursor . ",a:blinkon0"
  31.  
  32. set colorcolumn=80 textwidth=79
  33. set number
  34.  
  35. set langmap=ё`йqцwуeкrеtнyгuшiщoзpх[ъ]фaыsвdаfпgрhоjлkдlж\\;э'яzчxсcмvиbтnьmб\\,ю.Ё~ЙQЦWУEКRЕTНYГUШIЩOЗPХ{Ъ}ФAЫSВDАFПGРHОJЛKДLЖ:Э\\"ЯZЧXСCМVИBТNЬMЮ>Б<
  36. set pastetoggle=<F3>
  37.  
  38. set listchars=tab:»»,trail:·,nbsp:~,eol:$
  39. nnoremap th :tabfirst<CR>
  40. nnoremap tj :tabnext<CR>
  41. nnoremap tk :tabprev<CR>
  42. nnoremap tl :tablast<CR>
  43. nnoremap tn :tabnew<Space>
  44. nnoremap td :tabclose<CR>
  45.  
  46. " Highlight trailing whitespaces
  47. highlight ExtraWhitespace ctermbg=red guibg=red
  48. match ExtraWhitespace /\s\+$/
  49.  
  50. colorscheme desert
  51.  
  52. " In C++, do not indent public/private/protected keywords
  53. set cino=g0
  54.  
  55. " C-l to nohl
  56. nnoremap <silent> <C-l> :nohl<CR><C-l>
  57.  
  58. " load rules from the cwd
  59. set exrc
  60.  
  61. set tabpagemax=150
  62.  
  63. """ VUNDLE
  64. filetype off
  65. set rtp+=~/.vim/bundle/Vundle.vim
  66. call vundle#begin()
  67. Plugin 'VundleVim/Vundle.vim'
  68. Plugin 'editorconfig/editorconfig-vim'
  69. Plugin 'stfl/meson.vim'
  70. Plugin 'tmux-plugins/vim-tmux'
  71. Plugin 'rking/ag.vim'
  72. call vundle#end()
  73. filetype plugin indent on
  74. """ /VUNDLE
  75.  
  76. " configure ag.vim
  77. nnoremap ta :Ag "\b<C-R><C-W>\b"<CR>:cw<CR>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement