Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- filetype on
- set clipboard=unnamed
- set noswapfile
- " use ':so %' to refresh .vimrc without restarting vim
- set guifont=JetBrains_Mono:h10
- set ruler
- set ts=2
- set sw=2
- set smartindent
- set backspace=indent,eol,start
- " enter fullscreen
- au GUIEnter * simalt ~x
- cd ~/Documents/Code/cpp
- " key bindings
- imap jk <Esc>
- inoremap {<CR> {<CR><BS>}<Esc>O
- imap <C-BS> <C-W>
- noremap <C-a> <Esc>ggVG
- syntax enable
- autocmd filetype cpp nnoremap <F8> :w <bar> !cls && !g++ -g -O2 -std=c++11 % -o %:r -Wl,--stack,268435456<CR>
- autocmd filetype cpp nnoremap <F9> :w <bar> !cls && !g++ -g -O2 -std=c++11 % -o %:r -Wl,--stack,268435456 -D DEBUG<CR>
- autocmd filetype python nnoremap <F9> :w <bar> !python %:r.py<CR>
- autocmd filetype cpp nnoremap <F10> :!%:r <CR>
- autocmd filetype java nnoremap <F9> :w <bar> !java %:r<CR>
- " Go to C:\MinGW\bin and run mingw-get.exe install gdb
- autocmd filetype cpp nnoremap <F11> :w <bar> !gdb %:r<CR>
- set number
- augroup numbertoggle
- autocmd!
- autocmd BufEnter,FocusGained,InsertLeave * set relativenumber
- autocmd BufLeave,FocusLost,InsertEnter * set norelativenumber
- augroup END
- autocmd BufNewFile *.cpp 0r ~/Documents/Code/cpp/templ.cpp
- autocmd BufNewFile *.cpp norm ggO// Author: Wahyu Priambodo
- // Created: :put=strftime('%e %B %Y (%A)')
- kJ
- Gddk
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement