Last active
December 15, 2015 21:09
-
-
Save emachnic/5323530 to your computer and use it in GitHub Desktop.
This file contains 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
"""""""""" General Settings """""""""" | |
set nocompatible " be iMproved | |
filetype off " required! | |
filetype plugin indent on " required! | |
set clipboard=unnamed | |
set shiftwidth=2 | |
set tabstop=2 | |
"""""""""" End General Settings """""""""" | |
"""""""""" Vundle """""""""" | |
set rtp+=~/.vim/bundle/vundle/ | |
call vundle#rc() | |
" required! | |
Bundle 'gmarik/vundle' | |
" My Bundles here: | |
Bundle 'tpope/vim-fugitive' | |
Bundle 'kien/ctrlp.vim' | |
Bundle 'scrooloose/nerdtree' | |
Bundle 'tpope/vim-endwise' | |
Bundle 'mileszs/ack.vim' | |
Bundle 'altercation/vim-colors-solarized' | |
Bundle "myusuf3/numbers.vim" | |
Bundle 'Lokaltog/vim-powerline' | |
Bundle 'ervandew/supertab' | |
Bundle 'benmills/vimux' | |
Bundle 'tpope/vim-rails' | |
Bundle 'tpope/vim-bundler' | |
Bundle 'honza/snipmate-snippets' | |
Bundle 'jwhitley/vim-matchit' | |
Bundle "pangloss/vim-javascript" | |
Bundle 'cespare/vim-toml' | |
Bundle 'mattn/gist-vim' | |
Bundle 'mattn/webapi-vim' | |
"""""""""" End Vundle """""""""" | |
"""""""""" Number stuffz """""""""" | |
set relativenumber | |
" Toggle relativenumber on/off | |
function! NumberToggle() | |
if(&relativenumber == 1) | |
set number | |
else | |
set relativenumber | |
endif | |
endfunc | |
nnoremap <C-n> :call NumberToggle()<cr> | |
" Disable relativenumber when Vim loses focus | |
:au FocusLost * :set number | |
:au FocusGained * :set relativenumber | |
" Disable relativenumber when in Insert mode | |
autocmd InsertEnter * :set number | |
autocmd InsertLeave * :set relativenumber | |
"""""""""" End Number stuffz """""""""" | |
"""""""""" Gist """""""""" | |
let g:gist_clip_command = 'pbcopy' | |
let g:gist_detect_filetype = 1 | |
let g:gist_open_browser_after_post = 1 | |
let g:gist_post_private = 1 | |
"""""""""" End Gist """""""""" | |
"""""""""" Colorization """""""""" | |
syntax enable | |
set background=dark | |
colorscheme solarized | |
"""""""""" End Colorization """""""""" | |
"""""""""" NERD Tree """""""""" | |
nnoremap <leader>n :NERDTreeToggle .<CR> | |
"""""""""" End NERD Tree """""""""" | |
"""""""""" CtrlP """""""""" | |
let g:ctrlp_map = '<c-p>' | |
let g:ctrlp_cmd = 'CtrlP' | |
"""""""""" End CtrlP """""""""" | |
"""""""""" Vim Powerline """""""""" | |
let g:Powerline_symbols = 'fancy' | |
set t_Co=256 | |
set laststatus=2 | |
"""""""""" End Vim Powerline """""""""" | |
"""""""""" GUI configuration """""""""" | |
set guifont=Inconsolata-dz\ for\ Powerline\:h13 | |
set guioptions-=rL | |
"""""""""" End GUI configuration """""""""" | |
"""""""""" Vimux """""""""" | |
" Run the current file with rspec | |
map <Leader>rb :call VimuxRunCommand("clear; bundle exec rspec " . bufname("%"))<CR> | |
" Prompt for a command to run | |
map <Leader>rp :VimuxPromptCommand<CR> | |
" Run last command executed by VimuxRunCommand | |
map <Leader>rl :VimuxRunLastCommand<CR> | |
" Inspect runner pane | |
map <Leader>ri :VimuxInspectRunner<CR> | |
" Close all other tmux panes in current window | |
map <Leader>rx :VimuxClosePanes<CR> | |
" Close vim tmux runner opened by VimuxRunCommand | |
map <Leader>rq :VimuxCloseRunner<CR> | |
" Interrupt any command running in the runner pane | |
map <Leader>rs :VimuxInterruptRunner<CR> | |
" Give tmux pane 35% screen real estate | |
let g:VimuxHeight = "35" | |
" Split tmux pane horizontally (better on widescreen) | |
let g:VimuxOrientation = "h" | |
"""""""""" End Vimux """""""""" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment