mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-01-09 02:24:03 +01:00
Reset fino terminal color even if rvm/rbenv not present
This commit is contained in:
parent
397c085a19
commit
dc08a64287
1 changed files with 3 additions and 3 deletions
|
|
@ -27,17 +27,17 @@ function box_name {
|
||||||
|
|
||||||
local rvm_ruby=''
|
local rvm_ruby=''
|
||||||
if which rvm-prompt &> /dev/null; then
|
if which rvm-prompt &> /dev/null; then
|
||||||
rvm_ruby='‹$(rvm-prompt i v g)›%{$reset_color%}'
|
rvm_ruby='‹$(rvm-prompt i v g)›'
|
||||||
else
|
else
|
||||||
if which rbenv &> /dev/null; then
|
if which rbenv &> /dev/null; then
|
||||||
rvm_ruby='‹$(rbenv version | sed -e "s/ (set.*$//")›%{$reset_color%}'
|
rvm_ruby='‹$(rbenv version | sed -e "s/ (set.*$//")›'
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
local current_dir='${PWD/#$HOME/~}'
|
local current_dir='${PWD/#$HOME/~}'
|
||||||
local git_info='$(git_prompt_info)'
|
local git_info='$(git_prompt_info)'
|
||||||
|
|
||||||
|
|
||||||
PROMPT="╭─%{$FG[040]%}%n%{$reset_color%} %{$FG[239]%}at%{$reset_color%} %{$FG[033]%}$(box_name)%{$reset_color%} %{$FG[239]%}in%{$reset_color%} %{$terminfo[bold]$FG[226]%}${current_dir}%{$reset_color%}${git_info} %{$FG[239]%}using%{$FG[243]%} ${rvm_ruby}
|
PROMPT="╭─%{$FG[040]%}%n%{$reset_color%} %{$FG[239]%}at%{$reset_color%} %{$FG[033]%}$(box_name)%{$reset_color%} %{$FG[239]%}in%{$reset_color%} %{$terminfo[bold]$FG[226]%}${current_dir}%{$reset_color%}${git_info} %{$FG[239]%}using%{$FG[243]%} ${rvm_ruby}%{$reset_color%}
|
||||||
╰─$(virtualenv_info)$(prompt_char) "
|
╰─$(virtualenv_info)$(prompt_char) "
|
||||||
|
|
||||||
ZSH_THEME_GIT_PROMPT_PREFIX=" %{$FG[239]%}on%{$reset_color%} %{$fg[255]%}"
|
ZSH_THEME_GIT_PROMPT_PREFIX=" %{$FG[239]%}on%{$reset_color%} %{$fg[255]%}"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue