Created
February 13, 2017 04:45
-
-
Save zduey/c5ac8464ea1ca6a475da294ecce17907 to your computer and use it in GitHub Desktop.
My 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
set nocompatible | |
filetype off | |
" set the runtime path to include Vundle and initialize | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() | |
" let Vundle manage Vundle, required | |
Plugin 'gmarik/Vundle.vim' | |
" Add all plugins here | |
" Plugin 'Valloric/YouCompleteMe' | |
Plugin 'tmhedberg/SimpylFold' | |
Plugin 'vim-scripts/indentpython.vim' | |
Plugin 'scrooloose/syntastic' | |
Plugin 'nvie/vim-flake8' | |
Plugin 'jnurmine/Zenburn' | |
Plugin 'altercation/vim-colors-solarized' | |
Plugin 'scrooloose/nerdtree' | |
Plugin 'jistr/vim-nerdtree-tabs' | |
Plugin 'kien/ctrlp.vim' | |
Plugin 'tpope/vim-fugitive' | |
Plugin 'Lokaltog/powerline', {'rtp':'powerline/bindings/vim/'} | |
Plugin 'godlygeek/tabular' | |
Plugin 'plasticboy/vim-markdown' | |
" All of your Plugins must be added before the following line | |
call vundle#end() " required | |
filetype plugin indent on " required | |
" Shoe line number | |
set number | |
"split navigations | |
nnoremap <C-J> <C-W><C-J> | |
nnoremap <C-K> <C-W><C-K> | |
nnoremap <C-L> <C-W><C-L> | |
nnoremap <C-H> <C-W><C-H> | |
" Enable folding | |
set foldmethod=indent | |
set foldlevel=99 | |
" Enable folding with the spacebar | |
nnoremap <space> za | |
au BufNewFile,BufRead *.py | |
\ set tabstop=4 | | |
\ set softtabstop=4 | | |
\ set shiftwidth=4 | | |
\ set textwidth=79 | | |
\ set expandtab | | |
\ set autoindent | | |
\ set fileformat=unix | |
set encoding=utf-8 | |
" Custome setting for aut completion with YOUCOMPLETEME | |
let g:ycm_autoclose_preview_window_after_completion=1 | |
map <leader>g :YcmCompleter GoToDefinitionElseDeclaration<CR> | |
"python with virtualenv support | |
py << EOF | |
import os | |
import sys | |
if 'VIRTUAL_ENV' in os.environ: | |
project_base_dir = os.environ['VIRTUAL_ENV'] | |
activate_this = os.path.join(project_base_dir, 'bin/activate_this.py') | |
execfile(activate_this, dict(__file__=activate_this)) | |
EOF | |
"Syntax highlighting | |
let python_highlight_all=1 | |
syntax on | |
"Make toggling between backgrounds easy | |
call togglebg#map("<F5>") | |
let NERDTreeIgnore=['\.pyc$', '\~$'] "ignore files in NERDTree | |
if has('gui_running') | |
set background=dark | |
colorscheme solarized | |
else | |
colorscheme zenburn | |
endif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment