Skip to content

Commit a30b49c

Browse files
author
jedahan
committed
Breaking: use zsh statusline for GEOMETRY_INFO
1 parent a54a88f commit a30b49c

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

geometry.zsh

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -140,10 +140,8 @@ add-zsh-hook precmd geometry::prompt
140140
add-zsh-hook precmd geometry::rprompt
141141

142142
geometry::info() { # draw info if no command is given
143-
[[ -n "$BUFFER" ]] && { builtin zle accept-line && builtin return; }
144-
[[ -z "$GEOMETRY_INFO" ]] && { builtin zle accept-line && builtin return; }
145-
builtin echo ${(%):-$(geometry::wrap $PWD $GEOMETRY_INFO)}
146-
geometry::prompt
143+
([[ -n "$BUFFER" ]] || [[ -z "$GEOMETRY_INFO" ]]) && zle accept-line && return
144+
zle -M "${(%):-$(geometry::wrap $PWD $GEOMETRY_INFO)}"
147145
}
148146
builtin zle -N buffer-empty geometry::info
149147
builtin bindkey '^M' buffer-empty

0 commit comments

Comments
 (0)