Last active
December 12, 2015 03:09
-
-
Save rtorr/4705115 to your computer and use it in GitHub Desktop.
linux
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
# Check for an interactive session | |
[ -z "$PS1" ] && return | |
alias ls='ls --color=auto' | |
PS1='[\u@\h \W]\$ ' | |
export PATH=$PATH:~/.dropbox-dist:~/.scripts | |
# Preload the LibGL plugin | |
LD_PRELOAD=/usr/lib/libGL.so.1 | |
export PATH=$PATH:/home/rtorr/apps/google_appengine/ | |
export PATH=${PATH}:~/android-sdk-linux/tools | |
export PATH=${PATH}:~/android-sdk-linux/platform-tools | |
alias pycharm='cd /home/rtorr/apps/pycharm-2.6.3/ && bin/pycharm.sh' | |
alias webstorm='cd /home/rtorr/apps/WebStorm-121.390/ && bin/webstorm.sh' | |
alias ij='cd /home/rtorr/apps/idea-IU-123.123 && bin/idea.sh' | |
alias subl='apps/sublime/sublime_text' | |
#enable virtualenvwrapper | |
source /usr/local/bin/virtualenvwrapper.sh |
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
" Editor defaults | |
set ff=unix | |
set number | |
set nobackup | |
set ai | |
set modeline | |
set tabstop=2 softtabstop=2 shiftwidth=2 expandtab | |
set backspace=indent,eol,start | |
set nocompatible | |
set showmatch | |
set incsearch | |
set hidden | |
set history=1000 | |
set title | |
set ruler | |
set backupdir=/tmp | |
set directory=/tmp | |
set foldmethod=manual | |
" Syntax | |
syntax on | |
color twilight256 | |
syn on | |
set t_Co=256 | |
" Change tabline colors | |
hi! TabLineFill term=underline cterm=underline gui=underline | |
hi! TabLineFillEnd term=underline cterm=underline gui=underline | |
\ ctermfg=white ctermbg=black guifg=white guibg=black | |
" Save folds | |
" au BufWinLeave * silent! mkview | |
" au BufWinEnter * silent! loadview | |
" GUI Stuff | |
if has('gui_running') | |
set mouse=a | |
set background=light | |
color solarized | |
set guioptions+=mTrbLl | |
set guioptions-=mTrbLl | |
set guifont=DejaVu\ Sans\ Mono\ 10 | |
set cursorline | |
" Change font size | |
map <silent> <leader>+ :set guifont=DejaVu\ Sans\ Mono\ 14<CR> | |
map <silent> <leader>- :set guifont=DejaVu\ Sans\ Mono\ 10<CR> | |
endif | |
" Fix ' uselessness with marks | |
nnoremap ' ` | |
nnoremap ` ' | |
" Accomodate for your fat fingers | |
command! W w | |
" Leader | |
let mapleader = "," | |
" Insert a linebreak | |
noremap <leader>j i<Enter><Esc> | |
"Automatically reload .vimrc if it changes | |
autocmd! bufwritepost .vimrc source % | |
" Change tab stop | |
map <silent> <leader>t2 :set tabstop=2 softtabstop=2 shiftwidth=2 expandtab<CR> | |
map <silent> <leader>t4 :set tabstop=4 softtabstop=4 shiftwidth=4 expandtab<CR> | |
" Copy whole document to clipboard | |
map <silent> <leader>cd magg"+yG'a | |
" Paste from clipboard | |
map <silent> <leader>P <SHIFT>'+P | |
map <silent> <leader>p <SHIFT>'+p | |
" NERDTree | |
let NERDTreeChDirMode = 1 | |
map <silent> <leader>f :NERDTreeToggle<CR> | |
" Taglist | |
let Tlist_Use_Right_Window = 1 | |
let Tlist_GainFocus_On_ToggleOpen = 1 | |
let Tlist_Show_One_File = 1 | |
let Tlist_WinWidth = 40 | |
let Tlist_javascript_Hide_Extras = ['type'] | |
map <silent> <leader><space> :TlistToggle<CR> | |
" Better buffer management | |
map <silent> <leader>b :buffers<CR>:buffer<Space> | |
" Surround a line with a tag | |
map <leader>tw ysst | |
" Search | |
map <leader>s :execute "vimgrep /" . expand("<cword>") . "/j **" <Bar> cw<CR> | |
" Sudo write (,W) (stolen from gf3) | |
map <leader>W :w !sudo tee %<CR> |
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
# for mac keyboard layout (to update run xmodmap ~/.Xmodmap) | |
clear control | |
clear mod4 | |
keycode 105 = | |
keycode 206 = | |
keycode 133 = Control_L NoSymbol Control_L | |
keycode 134 = Control_R NoSymbol Control_R | |
keycode 37 = Super_L NoSymbol Super_L | |
add control = Control_L | |
add control = Control_R | |
add mod4 = Super_L |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment