diff options
author | Robby Russell <robby@planetargon.com> | 2012-01-25 18:14:29 -0800 |
---|---|---|
committer | Robby Russell <robby@planetargon.com> | 2012-01-25 18:14:29 -0800 |
commit | b56e37201dd6cf00a667daa1f033cfb1b1669b4a (patch) | |
tree | 0be7579715d81186b2ba2c8361ff620eb544d878 /themes/superjarin.zsh-theme | |
parent | 9dc9cae55f5aa9ab12db71da64ab062906d8504b (diff) | |
parent | 6496acf58bf8531809490b52e34811f74a27cc7c (diff) | |
download | zsh-b56e37201dd6cf00a667daa1f033cfb1b1669b4a.tar.gz zsh-b56e37201dd6cf00a667daa1f033cfb1b1669b4a.tar.bz2 zsh-b56e37201dd6cf00a667daa1f033cfb1b1669b4a.zip |
Merge pull request #860 from sbfaulkner/rbenv-support-for-themes
adding rbenv support to all the rvm themes
Diffstat (limited to 'themes/superjarin.zsh-theme')
-rw-r--r-- | themes/superjarin.zsh-theme | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/themes/superjarin.zsh-theme b/themes/superjarin.zsh-theme index 16eeb5316..0be816de0 100644 --- a/themes/superjarin.zsh-theme +++ b/themes/superjarin.zsh-theme @@ -1,5 +1,11 @@ # Grab the current version of ruby in use (via RVM): [ruby-1.8.7] -JARIN_CURRENT_RUBY_="%{$fg[white]%}[%{$fg[red]%}\$(~/.rvm/bin/rvm-prompt i v)%{$fg[white]%}]%{$reset_color%}" +if which rvm-prompt &> /dev/null; then + JARIN_CURRENT_RUBY_="%{$fg[white]%}[%{$fg[red]%}\$(~/.rvm/bin/rvm-prompt i v)%{$fg[white]%}]%{$reset_color%}" +else + if which rbenv &> /dev/null; then + JARIN_CURRENT_RUBY_="%{$fg[white]%}[%{$fg[red]%}\$(rbenv version | sed -e 's/ (set.*$//')%{$fg[white]%}]%{$reset_color%}" + fi +fi # Grab the current filepath, use shortcuts: ~/Desktop # Append the current git branch, if in a git repository |