Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix for wrong working dir showed on prompt when project .rvmrc is loa…

…ded.
  • Loading branch information...
commit c15ef56d74731eaf46b7d1a7df43ec1ac7aaec35 1 parent 5bef125
@marano marano authored wayneeseguin committed
Showing with 1 addition and 0 deletions.
  1. +1 −0  scripts/cd
View
1  scripts/cd
@@ -25,6 +25,7 @@ if [[ "$rvm_project_rvmrc" -ne 0 ]] ; then
fi
rvm_rvmrc_cwd="$cwd"
source "$cwd/.rvmrc"
+ cwd=$(dirname "$cwd")
fi
break
else

5 comments on commit c15ef56

@heimidal

As best as I can tell, this did not fix the "~rvm_rvmrc_cwd" issue for me.

@Sutto

do you use oh-my-zsh heimidal?

we finally worked out the fix to the bug - it seems there is an option (that oh-my-zsh sets
by default) that means zsh uses any variable with the current absolute path as the name
in the prompt. The fix is simple: add 'unsetopt auto_name_dirs' to your zshenv / comment
out the setopt for it in the existing oh-my-zsh files.

@Sutto

I forgot to mention - I plan on adding docs to the site for this shortly explaining the fix.

@marano

Sorry, after some time this solution stopped to work and I realize this wasn't the correct fix.
Thanks Sutto, now zsh is displaying the directory properly ;)

@wayneeseguin

OK. I've backed this out now. It essentially didn't do anything because of the break that is next.

Please sign in to comment.
Something went wrong with that request. Please try again.