Zsh: Remove o-m-z variable, fix preexec terminal title
Can't get number of jobs from subshell, so we put them in a variable.
This commit is contained in:
parent
0c0beeb071
commit
9b4035393a
|
@ -126,7 +126,6 @@ EOF
|
|||
|
||||
case ${TERM} in
|
||||
(xterm* | tmux* | rxvt* | screen* | alacritty)
|
||||
DISABLE_AUTO_TITLE="true"
|
||||
# Write some info to terminal title.
|
||||
# This is seen when the shell prompts for input.
|
||||
function _my_title_precmd() {
|
||||
|
@ -136,7 +135,8 @@ case ${TERM} in
|
|||
# Write command and args to terminal title.
|
||||
# This is seen while the shell waits for a command to complete.
|
||||
function _my_title_preexec() {
|
||||
printf "\e]0;%s: %s; %s\a" "${HOST}" "${1}" "$(print -Pn %~)"
|
||||
print -Pnv jobs_dir "%(1j,%j job%(2j|s|); ,)%~"
|
||||
printf "\e]0;%s: %s; %s\a" "${HOST}" "${1}" "${jobs_dir}"
|
||||
}
|
||||
add-zsh-hook preexec _my_title_preexec
|
||||
|
||||
|
|
Loading…
Reference in New Issue