Advertisement
Guest User

vimrc

a guest
Mar 22nd, 2018
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.67 KB | None | 0 0
  1. call plug#begin('~/.vim/plugged')
  2.  
  3. Plug 'scrooloose/nerdtree', { 'on': 'NERDTreeToggle' }
  4. Plug 'jiangmiao/auto-pairs'
  5. Plug 'kien/ctrlp.vim'
  6.  
  7. Plug 'morhetz/gruvbox'
  8.  
  9. call plug#end()
  10.  
  11. colorscheme gruvbox
  12. set background=dark
  13. set nocompatible
  14. set bs=indent,eol,start
  15. "set backup
  16. set viminfo='20,\"50
  17. set ruler
  18. set ai
  19. set showmatch
  20. set vb
  21. set ruler
  22. set laststatus=2
  23. set backspace=indent,eol,start
  24. set nocompatible
  25. set background=dark
  26. set showmode
  27. set clipboard=unnamed
  28. syntax on
  29. set number
  30. set incsearch
  31. set hlsearch
  32. set ignorecase
  33. set smartcase
  34. set termencoding=utf8
  35. set nocompatible
  36. set showcmd
  37. set foldenable
  38. set foldlevel=100
  39. set foldmethod=indent
  40. set mouse=a
  41. set mousemodel=popup
  42. set hidden
  43. set guioptions-=T
  44. set ch=1
  45. set mousehide
  46. set autoindent
  47. set nowrap
  48. set expandtab
  49. set shiftwidth=4
  50. set softtabstop=4
  51. set tabstop=4
  52. set smartindent
  53. set showmatch
  54. set lines=50
  55. set columns=140
  56. set iskeyword=@,48-57,_,192-255
  57. set backspace=indent,eol,start
  58. set history=200
  59. set wildmenu
  60. set list listchars=tab:>\ ,trail:·
  61. filetype plugin on
  62.  
  63. "mappings
  64.  
  65. map <C-n> :NERDTreeToggle<CR>
  66. map <silent> <C-h> :call WinMove('h')<CR>
  67. map <silent> <C-j> :call WinMove('j')<CR>
  68. map <silent> <C-k> :call WinMove('k')<CR>
  69. map <silent> <C-l> :call WinMove('l')<CR>
  70.  
  71. "function
  72.  
  73. function! SuperCleverTab()
  74. if strpart( getline('.'), 0, col('.')-1 ) =~ '^\s*$'
  75. return "\<Tab>"
  76. else
  77. return "\<C-p>"
  78. endif
  79. endfunction
  80.  
  81. function! WinMove(key)
  82. let t:curwin = winnr()
  83. exec "wincmd ".a:key
  84. if (t:curwin == winnr())
  85. if (match(a:key, '[jk];'))
  86. wincmd v
  87. else
  88. wincmd s
  89. endif
  90. exec "wincmd ".a:key
  91. endif
  92. endfunction
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement