Skip to content

Instantly share code, notes, and snippets.

@carlosvega20
Last active July 11, 2018 13:51
Show Gist options
  • Save carlosvega20/a66fe2ea76a6700e4ca6354a1787878f to your computer and use it in GitHub Desktop.
Save carlosvega20/a66fe2ea76a6700e4ca6354a1787878f to your computer and use it in GitHub Desktop.
set runtimepath^=~/.vim/bundle/ctrlp.vim
source ~/.vim/vundle
execute pathogen#infect()
syntax on
filetype plugin indent on
set background=dark
colorscheme solarized
colors zenburn
noremap <F1> :NERDTreeFind<ESC>
set tabstop=8
set expandtab
set shiftwidth=4
set softtabstop=4
set noswapfile
set cursorline
set number
autocmd Filetype html setlocal ts=2 sts=2 sw=2
autocmd Filetype ruby setlocal ts=2 sts=2 sw=2
autocmd Filetype javascript setlocal ts=2 sts=2 sw=2
# pen NERDTree and move the cursor to the file editing area
autocmd VimEnter * NERDTree | wincmd p
#Automatically close Nerdtree when tab is the last (:q)
autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif
let NERDTreeShowHidden=1
let NERDTreeIgnore=['\.DS_Store$', '\.vim$']
# Make TabNavigation position at right side of the screen
let g:NERDTreeWinPos = 'right'
cnoremap sudow w !sudo tee % >/dev/null
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment