Advertisement
Guest User

Untitled

a guest
Feb 23rd, 2018
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.90 KB | None | 0 0
  1. " Never hit escape again!
  2. imap jk <Esc>:w<CR>
  3.  
  4. " Use 256 colors!
  5. set t_Co=256
  6.  
  7. " utf-8 encoding baby!
  8. set encoding=utf-8
  9.  
  10. " Make sure I can spell
  11. " set spell spelllang=en_us
  12.  
  13. " Bye, bye arrow keys
  14. noremap <Up> <NOP>
  15. noremap <Down> <NOP>
  16. noremap <Left> <NOP>
  17. noremap <Right> <NOP>
  18.  
  19. " Saving undos forever
  20. set undofile
  21. set undodir=$HOME/.vim/undo/
  22.  
  23. " Syntax Highlighting
  24. syntax on
  25. let g:rehash256 = 1
  26. set background=dark
  27. "" colorscheme molokai
  28. "let g:molokai_original = 1
  29.  
  30. " Easy viewing of multiple files? Why not!
  31. set hidden
  32.  
  33. " Line Numbers
  34. set number
  35.  
  36. " What column am I in?
  37. set ruler
  38.  
  39. " Cool tab completion stuff
  40. set wildmenu
  41. set wildmode=list:longest,full
  42.  
  43. " Enable mouse support in console (Has issues with git)
  44. "set mouse=a
  45.  
  46. " Highlight things found with search
  47. set hlsearch
  48. set incsearch
  49.  
  50. " Why make search case sensitive?
  51. set ignorecase
  52.  
  53. " Highlight current line
  54. set cursorline
  55.  
  56. " Remove any trailing whitespace that is in the file
  57. autocmd BufRead,BufWrite * if ! &bin | silent! %s/\s\+$//ge | endif
  58.  
  59. " Who wants an 8 character tab? Not me!
  60. set shiftwidth=4
  61. set softtabstop=4
  62.  
  63. " Who doesn't like auto-indent?
  64. set autoindent
  65. set copyindent
  66.  
  67. " Spaces are better than a tab character
  68. set expandtab
  69. set smarttab
  70.  
  71. " This shows what you are typing as a command.
  72. set showcmd
  73.  
  74. " Show that filename in that bottom
  75. set ls=2
  76.  
  77. " Set that backspace to work
  78. set backspace=indent,eol,start
  79.  
  80. " Why backup when you can git?
  81. set nobackup
  82. set noswapfile
  83.  
  84. " Die annoying beep die!!!
  85. set visualbell
  86. set noerrorbells
  87.  
  88. " Get them 80 columns (Vim 7.3 and above)
  89. set colorcolumn=80
  90. "highlight OverLength ctermbg=red ctermfg=white guibg=#592929
  91. "match OverLength /\%81v.\+/
  92.  
  93. " Vundle Setup
  94. "" set nocompatible " be iMproved, required
  95. "" filetype off " required
  96.  
  97. " set the runtime path to include Vundle and initialize
  98. "" set rtp+=~/.vim/bundle/Vundle.vim
  99. "" call vundle#begin()
  100. " alternatively, pass a path where Vundle should install plugins
  101. "call vundle#begin('~/some/path/here')
  102.  
  103. "" Plugin 'gmarik/Vundle.vim'
  104. "" Plugin 'tpope/vim-fugitive'
  105. "" Plugin 'kien/ctrlp.vim'
  106. "" Plugin 'scrooloose/nerdtree'
  107. "" Plugin 'scrooloose/syntastic'
  108. "" Plugin 'Lokaltog/vim-powerline'
  109. "" Plugin 'sjl/gundo.vim'
  110. "" Plugin 'tpope/vim-surround'
  111. "" Plugin 'Lokaltog/vim-easymotion'
  112. "" Plugin 'chilicuil/conque'
  113. "" Plugin 'kien/rainbow_parentheses.vim'
  114. "" Plugin 'altercation/vim-colors-solarized'
  115. "" Plugin 'bling/vim-airline'
  116. "" Plugin 'fatih/vim-go'
  117. "" Plugin 'majutsushi/tagbar'
  118. "" Plugin 'nathanaelkane/vim-indent-guides'
  119. "" Plugin 'tomasr/molokai'
  120. "" Plugin 'elzr/vim-json'
  121. "" Plugin 'christoomey/vim-tmux-navigator'
  122. "" Plugin 'airblade/vim-gitgutter'
  123.  
  124. " All of your Plugins must be added before the following line
  125. "" call vundle#end() " required
  126. "" filetype plugin indent on " required
  127.  
  128. " OMG it's powerline!
  129. let g:airline_powerline_fonts = 1
  130. let g:airline_theme = 'powerlineish'
  131.  
  132. " Syntastic on by default
  133. let g:syntastic_mode_map = { 'mode': 'active',
  134. \ 'active_filetypes': [],
  135. \ 'passive_filetypes': [] }
  136.  
  137. " Check it on startup
  138. let g:syntastic_check_on_open = 1
  139. " Don't check syntax when you quit fool
  140. let g:syntastic_check_on_wq = 0
  141. " Got them pretty symbols
  142. let g:syntastic_error_symbol = '✗'
  143. let g:syntastic_warning_symbol = '⚠'
  144.  
  145. " Checkers
  146. let g:syntastic_python_checkers=['pyflakes']
  147. let g:syntastic_json_checkers=['jsonlint']
  148.  
  149. " NERDtree things
  150. nmap <C-l> :NERDTreeToggle<CR>
  151.  
  152. "Ctrl-p Stuff
  153. set runtimepath^=~/.vim/bundle/ctrlp.vim
  154. set wildignore+=*/tmp/*,*.so,*.swp,*.zip " MacOSX/Linux
  155. " set wildignore+=tmp\*,*.swp,*.zip,*.exe " Windows
  156. "" :helptags ~/.vim/bundle/ctrlp.vim/doc
  157. let g:ctrlp_working_path_mode = 2 " CtrlP: use the nearest ancestor that contains one of these directories or files: .git/ .hg/ .svn/ .bzr/ _darcs/
  158. let g:ctrlp_custom_ignore = {
  159. \ 'dir': '\.git$\|\.hg$\|\.svn$\|node_modules',
  160. \ 'file': '\.pyc$\|\.pyo$\|\.rbc$|\.rbo$\|\.class$\|\.o$\|\~$\|\.DS_Store',
  161. \ 'link': 'some_bad_symbolic_links',
  162. \ }
  163. let g:ctrlp_extensions = [
  164. \ 'ctrlp-filetpe',
  165. \ ]
  166. let g:ctrlp_follow_symlinks = 1
  167. let g:ctrlp_match_window_bottom = 0
  168. let g:ctrlp_match_window_reversed = 0
  169. nmap ; :CtrlPBuffer<CR>
  170. nnoremap <leader>. :CtrlPTag<cr>
  171.  
  172. " Rainbow parentheses colors.
  173. " Left column is for terminal environment.
  174. " Right column is for GUI environment.
  175. " Outermost is determined by last.
  176. let g:rbpt_colorpairs = [
  177. \ ['blue', '#FF6000'],
  178. \ ['cyan', '#00FFFF'],
  179. \ ['darkmagenta', '#CC00FF'],
  180. \ ['yellow', '#FFFF00'],
  181. \ ['red', '#FF0000'],
  182. \ ['darkgreen', '#00FF00'],
  183. \ ['White', '#c0c0c0'],
  184. \ ['blue', '#FF6000'],
  185. \ ['cyan', '#00FFFF'],
  186. \ ['darkmagenta', '#CC00FF'],
  187. \ ['yellow', '#FFFF00'],
  188. \ ['red', '#FF0000'],
  189. \ ['darkgreen', '#00FF00'],
  190. \ ['White', '#c0c0c0'],
  191. \ ['blue', '#FF6000'],
  192. \ ['cyan', '#00FFFF'],
  193. \ ['darkmagenta', '#CC00FF'],
  194. \ ['yellow', '#FFFF00'],
  195. \ ['red', '#FF0000'],
  196. \ ['darkgreen', '#00FF00'],
  197. \ ['White', '#c0c0c0'],
  198. \ ]
  199.  
  200. " Update this with the amount of supported colors
  201. "let g:rbpt_max = 21
  202. let g:rbpt_max = 21
  203.  
  204. " Turn rainbow parenthesis script on
  205. "au VimEnter * RainbowParenthesesToggle
  206. " These are necessary to re-load the stuff when syntax changes.
  207. "au Syntax * RainbowParenthesesLoadRound
  208.  
  209. "vim-indent-guides
  210. let g:indent_guides_start_level = 2
  211. let g:indent_guides_guid_size = 1
  212.  
  213. "vim-tmux-navigator
  214. let g:tmux_navigator_no_mappings = 1
  215.  
  216. nnoremap <silent> {Left-mapping} :TmuxNavigateLeft<cr>
  217. nnoremap <silent> {Down-Mapping} :TmuxNavigateDown<cr>
  218. nnoremap <silent> {Up-Mapping} :TmuxNavigateUp<cr>
  219. nnoremap <silent> {Right-Mapping} :TmuxNavigateRight<cr>
  220. nnoremap <silent> {Previous-Mapping} :TmuxNavigatePrevious<cr>
  221.  
  222. let g:tmux_navigator_save_on_switch = 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement