Created
January 18, 2016 17:02
-
-
Save jancuk/7718857734340a10f89c to your computer and use it in GitHub Desktop.
vimrc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "python from powerline.vim import setup as powerline_setup | |
| "python powerline_setup() | |
| "python del powerline_setup | |
| filetype on | |
| " bring in the bundles for mac and windows | |
| set rtp+=~/vimfiles/vundle.git/ | |
| set rtp+=~/.vim/vundle.git/ | |
| " au BufNewFile,BufRead *.rs set filetype=rust | |
| autocmd FileType * set tabstop=2|set shiftwidth=2|set expandtab | |
| autocmd FileType ruby set tabstop=2|set shiftwidth=2|set expandtab | |
| autocmd FileType scala set tabstop=2|set shiftwidth=2|set expandtab | |
| autocmd FileType python set tabstop=4|set shiftwidth=4|set expandtab | |
| autocmd FileType make set tabstop=4|set shiftwidth=4|set noexpandtab | |
| au BufEnter *.py set ai sw=4 ts=4 sta et fo=croql | |
| au BufNewFile,BufRead *.scala set filetype=scala | |
| call vundle#rc() | |
| let g:ackprg = 'ag --nogroup --nocolor --column' | |
| runtime! common_config/*.vim | |
| vmap <C-c> :w !pbcopy<cr><cr> | |
| set clipboard=unnamed | |
| filetype plugin on | |
| " set mouse-=a | |
| " | |
| " set nocp | |
| " noremap <Up> <NOP> | |
| " noremap <Down> <NOP> | |
| " noremap <Left> <NOP> | |
| " noremap <Right> <NOP> | |
| " | |
| set background=dark | |
| colorscheme vimbrant | |
| let g:airline_theme='light' | |
| set t_Co=256 | |
| highlight VertSplit ctermbg=236 | |
| highlight ColorColumn ctermbg=237 | |
| highlight LineNr ctermbg=236 ctermfg=240 | |
| highlight CursorLineNr ctermbg=236 ctermfg=240 | |
| highlight CursorLine ctermbg=236 | |
| highlight StatusLineNC ctermbg=238 ctermfg=0 | |
| highlight StatusLine ctermbg=240 ctermfg=12 | |
| highlight IncSearch ctermbg=0 ctermfg=3 | |
| highlight Search ctermbg=0 ctermfg=9 | |
| highlight Visual ctermbg=3 ctermfg=0 | |
| highlight Pmenu ctermbg=240 ctermfg=12 | |
| highlight PmenuSel ctermbg=0 ctermfg=3 | |
| highlight SpellBad ctermbg=0 ctermfg=1 | |
| highlight TabLineFill ctermfg=LightGreen ctermbg=DarkGreen | |
| highlight TabLine ctermfg=Black | |
| highlight TabLineSel ctermfg=Red ctermbg=Black | |
| highlight Title ctermfg=LightBlue | |
| highlight Search cterm=NONE ctermfg=Black ctermbg=DarkYellow | |
| "THEME SETTING | |
| " Map for switch Buffers | |
| map gn :bn<cr> | |
| map gp :bp<cr> | |
| map gd :bd<cr> | |
| let g:tmux_navigator_no_mappings = 1 | |
| let g:user_emmet_mode='a' | |
| let g:user_emmet_mode='n' | |
| let g:user_emmet_mode='inv' | |
| "Angular Complicated | |
| let g:angular_source_directory = 'app/source' | |
| let g:angular_test_directory = 'test/units' | |
| nnoremap <silent> {Left-mapping} :TmuxNavigateLeft<cr> | |
| nnoremap <silent> {Down-Mapping} :TmuxNavigateDown<cr> | |
| nnoremap <silent> {Up-Mapping} :TmuxNavigateUp<cr> | |
| nnoremap <silent> {Right-Mapping} :TmuxNavigateRight<cr> | |
| nnoremap <silent> {Previous-Mapping} :TmuxNavigatePrevious<cr> | |
| if exists('$ITERM_PROFILE') | |
| if exists('$TMUX') | |
| let &t_SI = "\<Esc>[3 q" | |
| let &t_EI = "\<Esc>[0 q" | |
| else | |
| let &t_SI = "\<Esc>]50;CursorShape=1\x7" | |
| let &t_EI = "\<Esc>]50;CursorShape=0\x7" | |
| endif | |
| end | |
| if &term =~ '^screen' | |
| execute "set <xUp>=\e[1;*A" | |
| execute "set <xDown>=\e[1;*B" | |
| execute "set <xRight>=\e[1;*C" | |
| execute "set <xLeft>=\e[1;*D" | |
| endif | |
| " Enable basic mouse behavior such as resizing buffers. | |
| set mouse=a | |
| if exists('$TMUX') " Support resizing in tmux | |
| set ttymouse=xterm2 | |
| endif | |
| " inside screen / tmux | |
| map <Esc>[C <C-Right> | |
| map <Esc>[D <C-Left> | |
| " insert mode | |
| map! <Esc>[C <C-Right> | |
| map! <Esc>[D <C-Left> | |
| " no screen | |
| map <Esc>[1;5D <C-Left> | |
| map <Esc>[1;5C <C-Right> | |
| " insert mode | |
| map! <Esc>[1;5D <C-Left> | |
| map! <Esc>[1;5C <C-Right> | |
| nnoremap <C-right> :tabnext<CR> | |
| nnoremap } :tabnext<CR> | |
| nnoremap <C-left> :tabprevious<CR> | |
| nnoremap { :tabprevious<CR> | |
| " insert mode | |
| inoremap <C-right> <Esc>:tabnext<CR> | |
| inoremap <C-left> <Esc>:tabprevious<CR> | |
| " paste mode insert | |
| function! WrapForTmux(s) | |
| if !exists('$TMUX') | |
| return a:s | |
| endif | |
| let tmux_start = "\<Esc>Ptmux;" | |
| let tmux_end = "\<Esc>\\" | |
| return tmux_start . substitute(a:s, "\<Esc>", "\<Esc>\<Esc>", 'g') . tmux_end | |
| endfunction | |
| let &t_SI .= WrapForTmux("\<Esc>[?2004h") | |
| let &t_EI .= WrapForTmux("\<Esc>[?2004l") | |
| function! XTermPasteBegin() | |
| set pastetoggle=<Esc>[201~ | |
| set paste | |
| return "" | |
| endfunction | |
| inoremap <special> <expr> <Esc>[200~ XTermPasteBegin() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment