yardnsm/blox-zsh-theme

Literal `tab_label` as cwd

tomterl opened this issue · 1 comments

I don't understand, what exactly is happening, but when some directories, instead of the home-adjusted path, a literal tab_label is printed as part of the prompt (blox_hook__title) after it was rendered correctly once:

/srv/www/projekt master[hash] ✘ $                                                                                             [[12:17]
 ❯

 ~tab_label master[hash] ✘ $                                                                                                         [12:17]
 ❯

If I change to title hook to

# ---------------------------------------------
# Hooks

# Set the title to cwd
function blox_hook__title() {
    echo -ne "\e]2;${PWD/${HOME}/\~}\a"
}

this does not happen. I do think it has to be something in my zsh setup, but I'm at a loss, what it could be.

(Feel free to close this as "Not a problem /here/", I just thought I'd ask)

Thanks for the report!
I couldn't find out what causes this issue as well. I'm fine with updating the code to the solution you've showed.

Would you like to open a PR?