oh-my-zsh/lib/rvm.zsh

9 lines
356 B
Bash
Raw Normal View History

# get the name of the ruby version
2010-05-19 06:53:16 +00:00
function rvm_prompt_info() {
2013-12-31 00:06:14 +00:00
[ -f $HOME/.rvm/bin/rvm-prompt ] || return 1
local rvm_prompt
2013-12-30 23:35:57 +00:00
rvm_prompt=$(eval "$HOME/.rvm/bin/rvm-prompt $ZSH_THEME_RVM_PROMPT_OPTIONS" 2>/dev/null)
2013-12-31 00:06:14 +00:00
[[ "${rvm_prompt}x" == "x" ]] && return 1
echo "${ZSH_THEME_RVM_PROMPT_PREFIX:=(}${rvm_prompt}${ZSH_THEME_RVM_PROMPT_SUFFIX:=)}"
2010-05-19 06:53:16 +00:00
}