-
Notifications
You must be signed in to change notification settings - Fork 7
/
zshrc
97 lines (72 loc) · 2.85 KB
/
zshrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
# Path to your oh-my-zsh configuration.
ZSH=$HOME/.rc/oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
ZSH_THEME="blinks-venv"
# Example aliases
# alias zshconfig="mate ~/.zshrc"
# alias ohmyzsh="mate ~/.oh-my-zsh"
# Set to this to use case-sensitive completion
# CASE_SENSITIVE="true"
# Comment this out to disable bi-weekly auto-update checks
# DISABLE_AUTO_UPDATE="true"
# Uncomment to change how many often would you like to wait before auto-updates occur? (in days)
# export UPDATE_ZSH_DAYS=13
# Uncomment following line if you want to disable colors in ls
# DISABLE_LS_COLORS="true"
# Uncomment following line if you want to disable autosetting terminal title.
# DISABLE_AUTO_TITLE="true"
# Uncomment following line if you want red dots to be displayed while waiting for completion
# COMPLETION_WAITING_DOTS="true"
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse)
plugins=(git osx python screen ssh-agent autojump coffee git-flow git-remote-branch vi-mode virtualenvwrapper)
source $ZSH/oh-my-zsh.sh
# Customize to your needs...
export PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin:$HOME/bin:/usr/local/bin:/usr/local/sbin:$HOME/.rvm/bin
# vi key binding
bindkey '^R' history-incremental-search-backward
export EDITOR=vim
source $ZSH/plugins/history-substring-search/history-substring-search.zsh
# HISTORY
# number of lines kept in history
export HISTSIZE=10000
# # number of lines saved in the history after logout
export SAVEHIST=10000
# # location of history
export HISTFILE=~/.zhistory
# # append command to history file once executed
setopt APPEND_HISTORY
# virtualenv and virtualenvwrapper
export VIRTUAL_ENV_DISABLE_PROMPT='1'
export WORKON_HOME=~/Envs
# alias
alias -g ...='../..'
alias -g ....='../../..'
alias -g .....='../../../..'
_VBoxManage() {
reply=(`VBoxManage 2>&1|awk '/VBoxManage [a-z]/ {print $2}'|uniq`)
}
compctl -K _VBoxManage VBoxManage
# psql
export PSQL_EDITOR='vim +"set syntax=sql"'
export YELLOW=`echo -e '\033[1;33m'`
export LIGHT_CYAN=`echo -e '\033[1;36m'`
export NOCOLOR=`echo -e '\033[0m'`
export LESS="-iMSx4 -FXR"
PAGER="sed \"s/\([[:space:]]\+-[0-9.]\+\)$/${LIGHT_CYAN}\1$NOCOLOR/;"
PAGER+="s/\([[:space:]]\+[0-9.\-]\+[[:space:]]\)/${LIGHT_CYAN}\1$NOCOLOR/g;"
PAGER+="s/|/$YELLOW|$NOCOLOR/g;s/^\([-+]\+\)/$YELLOW\1$NOCOLOR/\" 2>/dev/null | less"
export PAGER
# FASD https://github.com/clvv/fasd
export PATH=$PATH:$HOME/.rc/fasd
eval "$(fasd --init auto)"
alias v='f -e vim' # quick opening files with vim
alias j='fasd_cd -d'
alias jj='fasd_cd -d -i'
# tmuxifier
export PATH=$PATH:~/.rc/tmuxifier/bin
eval "$(tmuxifier init -)"