Change zsh auto titles to hide user and host

4

Right now, when I open a zsh termite terminal the window title is

user@host: ~

Is there any way to remove the user@host part without entirely disabling auto titles?

If I enable DISABLE_AUTO_TITLE in my .zshrc then the window title is always termite. I want to just change the window title when I'm browsing directories so that it doesn't show the user and host - only the directory, but if, for example, I open nmtui I want the window title to automatically become nmtui instead of staying as termite.

rococo

Posted 2017-08-21T07:14:40.713

Reputation: 201

Answers

6

Dug around a bit more and figured it out!

In my zsh theme (oh-my-via), I added this:

ZSH_THEME_TERM_TITLE_IDLE="%~"

which overrides the default value found here (ZSH_THEME_TERM_TITLE_IDLE="%n@%m: %~")

rococo

Posted 2017-08-21T07:14:40.713

Reputation: 201