1
0
mirror of https://github.com/robbyrussell/oh-my-zsh.git synced 2025-12-06 07:20:40 +01:00

handle case where ~/.rvm/bin/rvm-prompt is not in path, so "which" can't find it

This commit is contained in:
Brent Faulkner
2012-02-12 12:27:06 -05:00
parent fbf5b0ecb6
commit b62a3e8960
6 changed files with 6 additions and 6 deletions

View File

@@ -3,7 +3,7 @@
# Grab the current date (%D) and time (%T) wrapped in {}: {%D %T}
DALLAS_CURRENT_TIME_="%{$fg[white]%}{%{$fg[yellow]%}%D %T%{$fg[white]%}}%{$reset_color%}"
# Grab the current version of ruby in use (via RVM): [ruby-1.8.7]
if which rvm-prompt &> /dev/null; then
if [ -e ~/.rvm/bin/rvm-prompt ]; then
DALLAS_CURRENT_RUBY_="%{$fg[white]%}[%{$fg[magenta]%}\$(~/.rvm/bin/rvm-prompt i v)%{$fg[white]%}]%{$reset_color%}"
else
if which rbenv &> /dev/null; then