dotfiles/.vimrc

115 lines
2.2 KiB
VimL
Raw Normal View History

2016-01-24 19:32:42 +01:00
" Vundle package managment
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Plugin 'altercation/vim-colors-solarized'
Plugin 'gmarik/Vundle.vim'
Plugin 'bling/vim-airline'
Plugin 'easymotion/vim-easymotion'
Plugin 'ervandew/supertab'
Plugin 'hdima/python-syntax'
Plugin 'kien/ctrlp.vim'
Plugin 'majutsushi/tagbar'
Plugin 'mattn/emmet-vim'
Plugin 'octol/vim-cpp-enhanced-highlight'
Plugin 'scrooloose/syntastic'
Plugin 'Townk/vim-autoclose'
Plugin 'tpope/vim-fugitive'
Plugin 'tpope/vim-surround'
Plugin 'vim-scripts/a.vim'
Plugin 'vim-scripts/SearchComplete'
Plugin 'Valloric/YouCompleteMe'
call vundle#end()
set exrc
set secure
let g:ycm_global_ycm_extra_conf = '~/.vim/bundle/YouCompleteMe/.ycm_extra_conf.py'
let mapleader=","
" Autoindent for filetype
filetype plugin indent on
set autoindent
set encoding=utf-8
set scrolloff=4
set sidescrolloff=3
" Unsaved buffer switching
set hidden
" Line numbering
set number
set numberwidth=5
" Persistent undo
set undodir=~/.vim/undo/
set undofile
set undolevels=1000
set undoreload=10000
" Enable the mouse
:set mouse=a
" Python execution
:nnoremap <F5> :<C-u> ! python3 %<CR>
" Highlight line number of where cursor currently is
" Searching
set ignorecase
set smartcase
set incsearch
set hlsearch
nnoremap <leader><space> :noh<CR>
" Text wrapping
set lbr
" Tabs
if has("autocmd")
filetype plugin indent on
autocmd FileType make set tabstop=8 shiftwidth=8 softtabstop=0 noexpandtab
endif
" Terminal colors
set t_Co=256
set tabstop=4
set shiftwidth=4
set softtabstop=4
set expandtab
" Tab completion
set wildmode=longest,list
set wildmenu
" syntastic
" see .vim/after/ftplugin/python.vim as well
let g:syntastic_always_populate_loc_list = 1
set statusline+=%#warningmsg#
set statusline+=%{SyntasticStatuslineFlag()}
set statusline+=%*
let g:syntastic_auto_loc_list = 1
let g:syntastic_check_on_open = 1
let g:syntastic_check_on_wq = 1
set guifont=Ubuntu\ Mono\ derivative\ Powerline\ 13
let g:airline_powerline_fonts = 1
set laststatus=2
set ttimeoutlen=50
" Color scheme
syntax enable
set background=dark
let g:solarized_termcolors=256
colorscheme solarized
let g:tagbar_sort = 0
nnoremap <silent> <F9> :TagbarToggle<CR>