Use only command name in window title to avoid escaping issues

Was having issues with `%` characters in commands doing weird things.
Could alternatively strip those characters out or escape them, but that seemed harder
This commit is contained in:
Adam Goldsmith 2023-01-28 10:34:30 -05:00
parent a165991e9a
commit 87c935ffe5

2
.zshrc
View File

@ -19,7 +19,7 @@ SPROMPT='zsh: correct %F{red}%R%f to %F{green}%r%f [nyae]? '
WORDCHARS=${WORDCHARS//[\/]}
# Set window title format
zstyle ':zim:termtitle' format '%~:${1:-zsh}'
zstyle ':zim:termtitle' format '%~:${${(A)=1:-zsh}[1]}'
# Set window title before running a command
zstyle ':zim:termtitle' hooks 'precmd' 'preexec'