Last active
August 29, 2015 14:21
-
-
Save RyanParsley/43e683229c494a4092be to your computer and use it in GitHub Desktop.
My current .vimrc.after file
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
| let g:solarized_termcolors=256 | |
| let g:solarized_termtrans = 1 | |
| let g:syntastic_scss_checkers = ['scss_lint'] | |
| set background=dark | |
| color solarized | |
| colorscheme solarized | |
| set t_Co=16 | |
| nnoremap ,x :s/<[^>]*>/\r&\r/g<CR> | |
| nnoremap <leader><space> :noh<cr> | |
| nnoremap <leader>l :ls<CR>:b<space> | |
| set wrap | |
| set textwidth=0 wrapmargin=0 | |
| " Navigate splits more easily | |
| nmap <C-h> <C-w>h | |
| nmap <C-j> <C-w>j | |
| nmap <C-k> <C-w>k | |
| nmap <C-l> <C-w>l | |
| set clipboard=unnamed | |
| vmap <C-x> :!pbcopy<CR> | |
| vmap <C-c> :w !pbcopy<CR><CR> | |
| set wildignore+=*/tmp/*,*.so,*.swp,*.zip,*.jpg,*.png,*.jpeg,*.gif | |
| let g:ctrlp_custom_ignore = { 'dir': '\v[\/](node_modules|target|dist|vendor)|(\.(swp|ico|git|svn))$'} | |
| let g:angular_source_directory = 'app/src' | |
| syntax on | |
| filetype indent on | |
| set smartindent | |
| set tabstop=2 | |
| set shiftwidth=2 | |
| set autoread | |
| autocmd Filetype html nnoremap <leader>c I<!--<esc>A--><esc> | |
| autocmd Filetype javascript nnoremap <leader>c I//<esc> | |
| au! BufRead,BufNewFile *.json set filetype=json | |
| let g:vimwiki_ext2syntax = {'.md': 'markdown', '.markdown': 'markdown', '.mdown': 'markdown'} | |
| let g:syntastic_phpcs_conf=" --standard=DrupalCodingStandard --extensions=php,module,inc,install,test,profile,theme" | |
| let g:mustache_abbreviations = 1 | |
| let g:syntastic_filetype_map = { '.hbs': 'handlebars' } | |
| augroup json_autocmd | |
| autocmd! | |
| autocmd FileType json set autoindent | |
| autocmd FileType json set formatoptions=tcq2l | |
| autocmd FileType json set expandtab | |
| augroup END | |
| if has("autocmd") | |
| " Drupal *.module and *.install files. | |
| augroup module | |
| autocmd BufRead,BufNewFile *.module set filetype=php | |
| autocmd BufRead,BufNewFile *.install set filetype=php | |
| autocmd BufRead,BufNewFile *.test set filetype=php | |
| autocmd BufRead,BufNewFile *.inc set filetype=php | |
| autocmd BufRead,BufNewFile *.profile set filetype=php | |
| autocmd BufRead,BufNewFile *.view set filetype=php | |
| augroup END | |
| endif | |
| syntax on | |
| " Cursor shape fix for tmux | |
| 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 | |
| " for tmux to automatically set paste and nopaste mode at the time pasting (as | |
| " happens in VIM UI) | |
| 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