Advertisement
Guest User

vimrc

a guest
Oct 10th, 2015
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.19 KB | None | 0 0
  1.  
  2. " =============
  3.  
  4. " Table of contents
  5. " Basic Configuration
  6. " Vundle and Plugins
  7. " Indents, Tabshifts, etc.
  8.  
  9. " End TOC
  10.  
  11. "---------------------------------------------------------
  12.  
  13. set nocompatible " be iMproved, required
  14. filetype off " required
  15.  
  16. "------------------------------------------------------------------------
  17.  
  18. " set the runtime path to include Vundle and initialize
  19. set rtp+=~/.vim/bundle/Vundle.vim
  20. call vundle#begin()
  21.  
  22. " let Vundle manage Vundle, required
  23. Plugin 'gmarik/Vundle.vim'
  24.  
  25. " Track the engine.
  26. Plugin 'SirVer/ultisnips'
  27.  
  28.  
  29. " Installing Vim Markdown
  30. Plugin 'godlygeek/tabular'
  31. Plugin 'plasticboy/vim-markdown'
  32.  
  33.  
  34. " Trigger configuration. Do not use <tab> if you use https://github.com/Valloric/YouCompleteMe.
  35. let g:UltiSnipsExpandTrigger="<tab>"
  36. let g:UltiSnipsJumpForwardTrigger="<c-b>"
  37. let g:UltiSnipsJumpBackwardTrigger="<c-z>"
  38.  
  39. " If you want :UltiSnipsEdit to split your window.
  40. let g:UltiSnipsEditSplit="vertical"
  41. "
  42.  
  43. " All of your Plugins must be added before the following line
  44. call vundle#end() " required
  45. filetype plugin indent on " required
  46. " To ignore plugin indent changes, instead use:
  47. "filetype plugin on
  48. "
  49. " Brief help
  50. " :PluginList - lists configured plugins
  51. " :PluginInstall - installs plugins; append `!` to update or just :PluginUpdate
  52. " :PluginSearch foo - searches for foo; append `!` to refresh local cache
  53. " :PluginClean - confirms removal of unused plugins; append `!` to auto-approve removal
  54. "
  55. " 1ee :h vundle for more details or wiki for FAQ
  56. " Put your non-Plugin stuff after this line
  57.  
  58. "---------------------------------------------------------
  59.  
  60. " Indentation
  61. set tabstop=4
  62. set shiftwidth=4
  63. set cindent
  64. set autoindent
  65. set shiftround " TESTING
  66.  
  67. " Numberin g
  68. set relativenumber
  69. set number
  70.  
  71. " Coloring
  72. set t_Co=256
  73. colorscheme kolor
  74.  
  75. " Line Highlighting
  76. set cursorline
  77. set cursorcolumn
  78.  
  79. " Enhanced tab completion
  80. set wildmenu
  81.  
  82.  
  83. "------------------------------------------------------------------------
  84.  
  85. ""Echo example
  86. "echo ">^.^<"
  87. "
  88. "" Setting map leader and localleader
  89. let mapleader = "-"
  90. "let maplocalleader = "\\"
  91. "
  92. " open vimrc easily
  93. nnoremap <leader>ev :vsplit $MYVIMRC<cr>
  94. "
  95. " apply changes to current session
  96. nnoremap <leader>sv :source $MYVIMRC<cr>
  97. "
  98. "" adding test abbreviation
  99. "iabbrev ssig -- <cr>Sahil Manocha<cr>nukeballzy@gmail.com<cr>
  100. "
  101. "" encapsulate in quotes
  102. "vnoremap <leader>" <esc>`<i"<esc>`>a"<esc>
  103. "
  104.  
  105.  
  106. "" Status line
  107. "set statusline=%f " Path to the file
  108. "set statusline+=%= " Switch to the right side
  109. "set statusline+=%l " Current line
  110. "set statusline+=/ " Separator
  111. "set statusline+=%L " Total lines
  112.  
  113. "Vimscript file settings ---------------------{{{
  114. augroup filetype_vim
  115. autocmd!
  116. autocmd FileType vim setlocal foldmethod=marker
  117. augroup END
  118. "}}}
  119.  
  120. " File Specific ------------------------------{{{
  121. augroup filetype_c
  122. autocmd!
  123. autocmd FileType cpp nnoremap <F5> :w <cr> :!g++ -std=c++11 % -o %:r <cr>
  124. autocmd FileType cpp nnoremap <F6> :!./%:r <cr>
  125. augroup END
  126. "}}}
  127.  
  128.  
  129. "Abbreviations--------------------------------{{{
  130. iabbrev _rt <C-k>RT
  131. iabbrev _bc <C-k>:.
  132. "}}}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement