Created
March 5, 2015 12:51
-
-
Save pkazmierczak/e5d3f534d293a1142df5 to your computer and use it in GitHub Desktop.
My vim configuration
This file contains 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
set nocompatible | |
filetype off | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() | |
" Vundles! | |
Plugin 'gmarik/Vundle.vim' | |
Plugin 'tpope/vim-fugitive' | |
Plugin 'airblade/vim-gitgutter' | |
Plugin 'LaTeX-Box-Team/LaTeX-Box' | |
Plugin 'bling/vim-airline' | |
Plugin 'scrooloose/syntastic' | |
Plugin 'scrooloose/nerdtree' | |
Plugin 'sjl/gundo.vim' | |
Plugin 'tpope/vim-surround' | |
Plugin 'tpope/vim-unimpaired' | |
Plugin 'vim-pandoc/vim-pandoc' | |
Plugin 'vim-pandoc/vim-pandoc-syntax' | |
Plugin 'kshenoy/vim-signature' "for displaying marks | |
"Plugin 'kien/ctrlp.vim' | |
"Plugin 'mileszs/ack.vim' | |
Plugin 'Shougo/unite.vim' | |
Plugin 'Shougo/vimproc.vim' | |
Plugin 'klen/python-mode' | |
Plugin 'Valloric/YouCompleteMe' | |
" Clojure | |
Plugin 'guns/vim-clojure-static' | |
Plugin 'guns/vim-clojure-highlight' | |
Plugin 'kien/rainbow_parentheses.vim' | |
Plugin 'tpope/vim-fireplace' | |
" Plugin 'tpope/vim-leiningen' | |
Plugin 'vim-scripts/paredit.vim' | |
" colors | |
Plugin 'jonathanfilip/vim-lucius' | |
Plugin 'altercation/vim-colors-solarized' | |
Plugin 'reedes/vim-colors-pencil' | |
call vundle#end() " required | |
filetype plugin indent on " required | |
set number | |
set vb t_vb= | |
set smartindent | |
set clipboard=unnamed " yank and paste with the system clipboard | |
set guioptions-=L " no scrollbars | |
set guioptions-=r " no scrollbars | |
set ts=2 sts=2 sw=2 expandtab tw=72 | |
if has("mac") | |
set guifont=Source\ Code\ Pro\ for\ Powerline:h13 | |
else | |
set guifont=Inconsolata\ 11 | |
endif | |
set laststatus=2 | |
syntax on | |
set autochdir | |
" I think this is better for latex | |
nnoremap k gk | |
nnoremap gk k | |
nnoremap j gj | |
nnoremap gj j | |
nnoremap U :GundoToggle<cr> | |
nnoremap <F5> :buffers<CR>:buffer<Space> | |
" fugitive! | |
nnoremap <leader>gw :Gwrite<cr> | |
nnoremap <leader>gs :Gstatus<cr> | |
nnoremap <leader>gc :Gcommit<cr> | |
nnoremap <leader>gp :Git push<cr> | |
" Clojure | |
nnoremap <leader>rr :RainbowParenthesesToggle<cr> | |
nnoremap <leader>ee :%Eval<cr> | |
" Python | |
let g:pymode_rope_completion = 0 | |
let g:pymode_rope_complete_on_dot = 0 | |
let g:pymode_warnings = 0 | |
let g:pymode_trim_whitespaces = 1 | |
let g:pymode_folding = 0 | |
let g:pymode_lint_checkers = ['pep8'] | |
let g:pymode_lint_ignore = "W" | |
let g:pymode_lint_cwindow = 0 | |
" insert empty line without entering insert mode | |
" http://vim.wikia.com/wiki/Insert_newline_without_entering_insert_mode | |
nmap <S-Enter> O<Esc> | |
nmap <CR> o<Esc> | |
colorscheme pencil | |
set background=light | |
call togglebg#map("<F6>") | |
" colorscheme lucius | |
" let g:lucius_style = 'light' | |
" nnoremap <F6> :call ToggleColor()<cr> | |
" | |
" function! ToggleColor() | |
" if (g:lucius_style == 'light') | |
" LuciusDark | |
" else | |
" LuciusLight | |
" endif | |
" endfunction | |
" set background=light | |
" " let g:solarized_contrast = 'low' | |
" colorscheme solarized | |
" " Toggle 'night mode' | |
" call togglebg#map("<F6>") | |
" Source the vimrc file after saving it | |
if has("autocmd") | |
autocmd bufwritepost .vimrc source $MYVIMRC | |
endif | |
au FileType * exec("setlocal dictionary+=".$HOME."/.vim/dictionaries/".expand('<amatch>')) | |
set complete+=k | |
" airline | |
let g:airline#extensions#tabline#enabled = 1 | |
let g:airline_powerline_fonts = 1 | |
let g:airline_theme='pencil' | |
let g:airline#extensions#whitespace#enabled = 0 | |
" Unite | |
nnoremap <C-p> :Unite file_rec/async<cr> "file searching | |
nnoremap <space>/ :Unite grep:.<cr> "content searching | |
nnoremap <space>s :Unite -quick-match buffer<cr> "buffer switching | |
" LaTeX | |
set nospell | |
autocmd BufNewFile,BufRead *.tex set spell | |
set conceallevel=0 | |
let g:tex_conceal= 'adgms' | |
let g:LatexBox_latexmk_options = "-pdf" | |
let g:LatexBox_latexmk_async = 1 | |
let g:LatexBox_fold_toc = 0 | |
nmap <buffer> <F5> <Plug>LatexChangeEnv | |
vmap <buffer> <F7> <Plug>LatexWrapSelection | |
let g:LatexBox_quickfix = 0 | |
if has("mac") | |
let g:LatexBox_viewer = "open" | |
else | |
let g:LatexBox_viewer = "xdg-open" | |
endif | |
let g:syntastic_mode_map = { 'mode': 'active', | |
\ 'active_filetypes': [], | |
\ 'passive_filetypes': ['tex'] } | |
let g:syntastic_quiet_messages = { "level": "warnings", | |
\ "type": "style",} | |
" NerdTree | |
map <C-n> :NERDTreeToggle<CR> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment