Skip to content

Commit ee704a2

Browse files
committed
Code cleanup
1 parent c198e95 commit ee704a2

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

agkozak-zsh-prompt.plugin.zsh

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -604,14 +604,15 @@ _agkozak_precmd() {
604604
psvar[1]=''
605605
fi
606606

607-
# The DragonFly BSD console
608-
[[ $TERM == 'cons25' ]] && unset zle_bracketed_paste
609-
610-
# The Emacs shell has only limited support for some ZSH features
611-
if [[ $TERM == 'dumb' ]]; then
612-
# Avoid the ugly ^[[?2004h control sequence
607+
# The DragonFly BSD console and Emacs shell can't handle bracketed paste.
608+
# Let's avoid the ugly ^[[?2004 control sequence.
609+
if [[ $TERM == 'cons25' ]] || [[ $TERM == 'dumb' ]]; then
613610
unset zle_bracketed_paste
611+
fi
614612

613+
# The Emacs shell has only limited support for some ZSH features, so we use a
614+
# more limited prompt.
615+
if [[ $TERM == 'dumb' ]]; then
615616
PROMPT='%(?..(%?%) )'
616617
PROMPT+='%n%1v '
617618
PROMPT+='$(_agkozak_prompt_dirtrim "$AGKOZAK_PROMPT_DIRTRIM")'

0 commit comments

Comments
 (0)