Advertisement
Guest User

Untitled

a guest
Apr 10th, 2018
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VIM 2.91 KB | None | 0 0
  1. call pathogen#infect()
  2.  
  3. execute pathogen#infect()
  4.  
  5. syntax on
  6. filetype plugin indent on
  7. set nowrap
  8. set nu
  9. set relativenumber
  10.  
  11. set clipboard=unnamed
  12. nnoremap <C-S-p> r !pbpaste<CR>
  13.  
  14. "timeouts for the noremappings
  15. set timeoutlen=175
  16. imap <ESC><ESC> <ESC><S-a>
  17. " show existing tab with 4 spaces width
  18. set tabstop=2
  19. " when indenting with '>', use 4 spaces width
  20. set shiftwidth=2
  21. " On pressing tab, insert 4 spaces
  22. set expandtab
  23. set nocompatible              
  24. filetype off                  
  25.  
  26. set rtp+=~/.vim/bundle/Vundle.vim
  27. call vundle#begin()
  28.  
  29. Plugin 'VundleVim/Vundle.vim'
  30. Plugin 'udalov/kotlin-vim'
  31. Plugin 'tpope/vim-fugitive'
  32. Plugin 'tpope/vim-surround'
  33. Plugin 'ervandew/supertab'
  34. Plugin 'sheerun/vim-polyglot'
  35.  
  36. call vundle#end()
  37. filetype plugin indent on
  38.  
  39. call plug#begin('~/.vim/plugged')
  40. Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' }
  41. Plug 'junegunn/fzf.vim'
  42. call plug#end()
  43.  
  44. let g:syntastic_always_populate_loc_list = 1
  45. let g:syntastic_auto_loc_list = 1
  46. let g:syntastic_check_on_open = 1
  47. let g:syntastic_check_on_wq = 0
  48. "Auto plugin commands config
  49. "au FileType markdown,text,tex DittoOn
  50. """"""""""""""""""""""""""""""""""""""""""
  51. map <C-j> <C-W>j
  52. map <C-k> <C-W>k
  53. map <C-h> <C-W>h
  54. map <C-l> <C-W>l
  55. """"""""""""""""""""""""""""""""""""""""""
  56. " Set leader
  57. let mapleader = ","
  58. "map to dev/null
  59. map <leader>d "_x
  60.  
  61. """"""""""""""""""""""""""""""""""""""""""
  62. "paste
  63. nnoremap <leader>p "+p
  64.  
  65. " changing directory shortcuts
  66. nnoremap <leader>ch :cd ../<CR><CR>:pwd<CR>
  67. nnoremap <leader>cd :cd %:p:h<CR>:pwd<CR>
  68.  
  69. "test
  70. "=============================
  71. " Custom shortcuts
  72. "=============================
  73.  
  74. " TimeStamp
  75. noremap <leader>ts i<C-R>=strftime("%Y-%m-%d %a %I:%M %p")<CR><Esc>
  76. " map source rc command
  77. noremap <leader>! :source ~/.vimrc<CR>
  78. " map save func
  79. nnoremap <leader>w :w<CR>
  80.  
  81. map <leader>f "qp
  82.  
  83.  
  84. " default the statusline to green when entering Vim
  85. hi statusline guibg=DarkGrey ctermfg=8 guifg=White ctermbg=15
  86.  
  87. " Formats the statusline
  88. set statusline=%f                           " file name
  89. set statusline+=[%{strlen(&fenc)?&fenc:'none'}, "file encoding
  90. set statusline+=%{&ff}] "file format
  91. set statusline+=%y      "filetype
  92. set statusline+=%h      "help file flag
  93. set statusline+=%m      "modified flag
  94. set statusline+=%r      "read only flag
  95.  
  96. set statusline+=\ %=                        " align left
  97. set statusline+=Line:%l/%L[%p%%]            " line X of Y [percent of file]
  98. set statusline+=\ Col:%c                    " current column
  99. set statusline+=\ Buf:%n                    " Buffer number
  100. set statusline+=\ [%b][0x%B]\               " ASCII and byte code under cursor
  101.  
  102. nnoremap <leader><ESC> :FZF<CR>
  103. nnoremap <F12> :read !date +\%D@\%T<CR>
  104.  
  105.  
  106.  
  107. nnoremap gb :ls<CR>:b<Space>
  108. nnoremap <leader>r :MRU<CR>
  109. nnoremap <leader><Tab> :FZF ./<CR>
  110. set statusline+=%#warningmsg#
  111. set statusline+=%{SyntasticStatuslineFlag()}
  112. set statusline+=%*
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement