Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

This is related to Zsh: Open a new tab in the same directory. I have installed oh-my-zsh recently and it certainly kicks. I have some custom variables, like $WORKSPACE which I use to get around easily. And when I am inside one of those paths the prompt gets set to the name of the variable, for example ~WORKSPACE/project $ .
This breaks the "Open tab in the same directory feature" which I love so much. And whats puzzling me most here is that this does not happen for the ZSH variable. So cd $ZSH gives a prompt like ~/.oh-my-zsh $. And as far as I know they are bot set the same way in my .zshrc

ZSH=$HOME/.oh-my-zsh
WORKSPACE=$HOME/workspace
share|improve this question
    
Figured out as I was writing. The problem was that I was setting the custom vars after oh-my-zsh was loaded. Moving them up solved the problem, but I still dont understand what happened. Maybe its a oh-my-zsh feature? –  Paulo Casaretto Sep 6 '12 at 19:55
    
If you've answered your question, you should type it up as an "answer" below and accept it. It will be more useful to people that land here in the future. :) –  JoshP Sep 26 '12 at 13:57
    
Oops, forgot to. SU had a time period before I could do that. –  Paulo Casaretto Sep 26 '12 at 16:27

1 Answer 1

up vote 4 down vote accepted

Oh-my-zsh was setting auto_name_dirs which caused this behaviour.
I just commented out that line from lib/directories.zsh and everything went back to the way I wanted them.

share|improve this answer
    
So... is this the answer to the question? I still don't know how to prevent zsh from setting the current prompt to the name of the variable that points to this path... –  Sebastián Grignoli Apr 23 '13 at 15:14
    
Updated the answer, thanks for bringing this up again. –  Paulo Casaretto Apr 23 '13 at 16:24
    
Thank you! That worked fine. –  Sebastián Grignoli Apr 23 '13 at 17:53
    
Dont forget to vote me up! :) –  Paulo Casaretto Apr 23 '13 at 18:05

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.