Skip to content

Instantly share code, notes, and snippets.

@hgoldstein95
Created December 21, 2015 13:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hgoldstein95/48ecdc358101eec67cf2 to your computer and use it in GitHub Desktop.
Save hgoldstein95/48ecdc358101eec67cf2 to your computer and use it in GitHub Desktop.
" --------------------------
" Harrison Goldstein's VIMRC
" --------------------------
" Vudle
set nocompatible
filetype off
set rtp+=~/.vim/bundle/vundle.vim
call vundle#begin()
Plugin 'VundleVim/vundle.vim'
Plugin 'git@github.com:scrooloose/nerdtree.git'
Plugin 'git@github.com:easymotion/vim-easymotion.git'
Plugin 'git@github.com:tomasr/molokai.git'
Plugin 'git@github.com:tpope/vim-surround.git'
Plugin 'mattn/webapi-vim'
Plugin 'mattn/gist-vim'
call vundle#end()
filetype plugin indent on
" Map <leader> to space
let mapleader = " "
" Simple syntax hilighting
syntax on
" Tab stuff
set noexpandtab
set tabstop=2
set softtabstop=2
set autoindent
" Set default line numbering
set relativenumber
set number
" Change line numbering with <leader>n
nnoremap <leader>n :call RelNumberToggle()<cr>
function! RelNumberToggle()
if &relativenumber
set norelativenumber
else
set relativenumber
endif
endfunction
nnoremap <C-t> :tabnew<cr>
" Map save with Ctrl-s ONLY WORKS IF stty -ixon is on in .zshrc/.bashrc
nnoremap <C-s> :w<cr>
inoremap <C-s> <esc>:w<cr>
nnoremap <up> ddkP
nnoremap <down> ddp
nnoremap <left> <nop>
inoremap <right> <nop>
inoremap <left> <nop>
nnoremap <right> <nop>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment