Skip to content

Instantly share code, notes, and snippets.

@kazshu
Created February 13, 2013 12:08
Show Gist options
  • Select an option

  • Save kazshu/4944173 to your computer and use it in GitHub Desktop.

Select an option

Save kazshu/4944173 to your computer and use it in GitHub Desktop.
# Path to your oh-my-zsh configuration.
ZSH=$HOME/.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="bira"
ZSH_THEME="robbyrussell"
# 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 weekly auto-update checks
# DISABLE_AUTO_UPDATE="true"
# 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 autojump zsh-syntax-highlighting)
source $ZSH/oh-my-zsh.sh
# Customize to your needs...
precmd () {
RPROMPT="%F{red}[`ruby -v | awk '{print $1,$2}'`]%f"
}
function rezeus() {
\rm .zeus.sock || true
ps -ef | grep zeus | awk ' { print $2 } ' | xargs kill || true
zeus start
}
# 自動補完
# autoload predict-on
# predict-on
## 履歴の保存先
HISTFILE=$HOME/.zsh_history
## メモリに展開する履歴の数
HISTSIZE=100000
## 保存する履歴の数
SAVEHIST=100000
## 補完機能の強化
autoload -U compinit
compinit -u
## 直前と同じコマンドをヒストリに追加しない
setopt hist_ignore_dups
## TAB で順に補完候補を切り替える
setopt auto_menu
## 補完候補のカーソル選択を有効に
zstyle ':completion:*:default' menu select=1
## 補完候補を詰めて表示
setopt list_packed
## コマンドラインでも # 以降をコメントと見なす
setopt interactive_comments
## ファイル名の展開でディレクトリにマッチした場合末尾に / を付加する
setopt mark_dirs
alias b='bundle'
alias be='bundle exec'
alias ber='bundle exec rails'
alias r='rails'
alias ss='bundle exec rspec --drb --color'
alias ssall='bundle exec rspec --drb --color spec/'
alias sc='bundle exec cucumber --drb --port 8990'
alias cpork='RAILS_ENV=cucumber bundle exec spork cuc --port 8990'
alias alltest='rake spec cucumber'
alias rezsh='source ~/.zshrc'
alias glr='git pull --rebase origin $(current_branch)'
alias grm='git rebase master'
alias s='subl'
alias zsall='zeus rspec spec'
eval "$(rbenv init -)"
export NODE_PATH=/usr/local/lib/node_module
PATH=/usr/local/sbin:~/bin:$PATH
[ -f ~/.zshrc.local ] && source ~/.zshrc.local
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment