ohmyzsh/lib/rvm.zsh

9 lines
356 B
Bash
Raw Normal View History

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