Skip to content

Instantly share code, notes, and snippets.

@ngoduykhanh
Last active April 17, 2016 16:55
Show Gist options
  • Save ngoduykhanh/1d9a39b3bfebba5b5b1a to your computer and use it in GitHub Desktop.
Save ngoduykhanh/1d9a39b3bfebba5b5b1a to your computer and use it in GitHub Desktop.
set shell=/bin/bash " require for vim-gitgutter
set mouse=a " allow scroll up/down inside vim
set tabstop=4 " number of visual spaces per TAB
set softtabstop=4 " number of spaces in tab when editing
set expandtab " tabs are spaces
set showcmd " show command in bottom bar
set cursorline " highlight current line
set wildmenu " visual autocomplete for command menu
set lazyredraw " redraw only when we need to.
set showmatch " highlight matching [{()}]
set incsearch " search as characters are entered
set hlsearch " highlight matches
set modeline " allow mode config in the file
filetype indent on " load filetype-specific indent fies
colorscheme badwolf " awesome colorscheme
syntax enable " enable syntax processing
"Plugin for plugin management
execute pathogen#infect()
"Toggle folder tree by NREDTree
map <C-n> :NERDTreeToggle<CR>
"close vim if the only window left open is a NERDTree
autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTreeType") && b:NERDTreeType == "primary") | q | endif
"TAB for code completion
au FileType python set omnifunc=pythoncomplete#Complete
let g:SuperTabDefaultCompletionType = "context"
set completeopt=menuone,longest,preview
"configure inden for python
au FileType python setl shiftwidth=4 tabstop=4
"load ctrlp
set runtimepath^=~/.vim/bundle/ctrlp.vim
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment