From 829f267657a7aea54ccd3673ecf283bb3c6de003 Mon Sep 17 00:00:00 2001 From: Christopher Sexton Date: Wed, 2 Mar 2011 10:41:10 -0500 Subject: [PATCH] Removing hard coded parens from rvm_prompt_info I wanted to make use of rvm_prompt_info's error checking, but the existin funciton had hard coded parens wrapping the ruby version. This made for some odd behavior when using the system ruby (i.e. empty parens in the prompt), and was not customizable. This should resolve the issue. Updated risto theme to match. --- lib/rvm.zsh | 2 +- themes/risto.zsh-theme | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/rvm.zsh b/lib/rvm.zsh index 597be1b33..440f77c79 100644 --- a/lib/rvm.zsh +++ b/lib/rvm.zsh @@ -1,7 +1,7 @@ # get the name of the branch we are on function rvm_prompt_info() { ruby_version=$(~/.rvm/bin/rvm-prompt 2> /dev/null) || return - echo "($ruby_version)" + echo "$ruby_version" } diff --git a/themes/risto.zsh-theme b/themes/risto.zsh-theme index dc94acd7c..a21f4f6f0 100644 --- a/themes/risto.zsh-theme +++ b/themes/risto.zsh-theme @@ -3,7 +3,7 @@ # Requires the svn plugin # PROMPT='%{$fg[green]%}%n@%m:%{$fg[blue]%}%2~ $(svn_prompt_info)$(git_prompt_info)%{$reset_color%}%(!.#.%%) ' -RPROMPT='%{$fg_bold[red]%}$(rvm-prompt)%{$reset_color%}%' +RPROMPT='%{$fg_bold[red]%}$(rvm_prompt_info)%{$reset_color%}%' ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[red]%}‹" ZSH_THEME_GIT_PROMPT_SUFFIX="%{$fg[red]%}›%{$reset_color%}"