Guest User

Untitled

a guest
Oct 8th, 2020
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VIM 2.24 KB | None | 0 0
  1. set ffs=unix,dos
  2. let g:clang_library_path='/usr/lib/llvm-6.0/lib'
  3. set nocompatible              " be iMproved, required
  4. filetype off                  " required
  5. set rtp+=~/.vim/bundle/Vundle.vim
  6. call vundle#begin()
  7. Plugin 'VundleVim/Vundle.vim'
  8.  
  9. call vundle#end()            " required
  10. filetype plugin indent on    " required
  11.  
  12. " :PluginList       - lists configured plugins
  13. " :PluginInstall    - installs plugins; append `!` to update or just :PluginUpdate
  14. " :PluginSearch foo - searches for foo; append `!` to refresh local cache
  15. " :PluginClean      - confirms removal of unused plugins; append `!` to auto-approve removal
  16. " see :h vundle for more details or wiki for FAQ
  17.  
  18.  
  19. syntax on
  20.  
  21. "wildmenu lazyredraw visualbell number ruler expandtab tabstop shiftwidth autoindent smarttab smartindent
  22. set wmnu lz vb nu ru et ts=4 sw=4 ai sta si
  23. set gfn=consolas "guifont
  24.  
  25. set spr sb "splitright splitbelow
  26. set hls is ar "hlsearch incsearch autoread
  27.  
  28. set guioptions-=T
  29. set guioptions-=m
  30.  
  31. set mouse=a
  32. set showcmd
  33.  
  34. set whichwrap+=<,>,[,]
  35. set backspace=indent,eol,start
  36.  
  37. "========================================
  38. function! Setup()
  39.     vs $HOME/vim_gcc/source.cpp
  40.     silent only!
  41.     silent tabonly!
  42.     vs $HOME/vim_gcc/input.txt
  43.     sp $HOME/vim_gcc/output.txt
  44.     tabnew $HOME/vim_gcc/CompileMessage.txt
  45.     tabp
  46.     silent execute "normal \<C-w>h\<C-w>k"
  47. endfunction
  48.  
  49.  
  50. nnoremap <silent> <F6> :wa<CR><C-w>h<C-w>k :!g++ -D_MY -Wall -Wno-unused-result -std=c++17 -g % -o %:r <CR>
  51. nnoremap <silent> <F5> :wa<CR><C-w>h<C-w>k :!g++ -D_MY -Wall -Wno-unused-result -std=c++17 -g % -o %:r && ./%:r <CR>
  52.  
  53.  
  54. vmap <C-c> "+y
  55. nmap <C-a> ggVG
  56. nmap <C-v> "+gp
  57. vmap <C-v> "+gp
  58. imap <C-v> <esc><C-v>a
  59. nnoremap <C-b> <C-v>
  60. inoremap ( ()<Left>
  61. inoremap [ []<Left>
  62. inoremap { {}<Left>
  63. inoremap <expr> )  strpart(getline('.'), col('.')-1, 1) == ")" ? "\<Right>" : ")"
  64. inoremap <expr> ]  strpart(getline('.'), col('.')-1, 1) == "]" ? "\<Right>" : "]"
  65. inoremap <expr> }  strpart(getline('.'), col('.')-1, 1) == "}" ? "\<Right>" : "}"
  66. inoremap <expr> <Enter> strpart(getline('.'), col('.')-2, 2) != "{}" ? "\<Enter>" : "\<CR>\<Tab>\<CR>\<Up>\<Esc>$a"
  67.  
  68. "-----ONLY--LOCAL------
  69. let teach = 0
  70. if teach == 1
  71.         syntax off
  72.             colorscheme shine
  73.         endif
  74.  
Advertisement
Add Comment
Please, Sign In to add comment