summaryrefslogtreecommitdiff
path: root/plugins/fancy-ctrl-z/fancy-ctrl-z.plugin.zsh
diff options
context:
space:
mode:
authormickk-on-cpp <mickk-on-cpp@users.noreply.github.com>2020-02-28 17:27:16 +0100
committerGitHub <noreply@github.com>2020-02-28 17:27:16 +0100
commit08b04f5df2b9a4747b8f8975785bdcd523d85445 (patch)
tree08562706699ef419674d379f625428fa69cf48c0 /plugins/fancy-ctrl-z/fancy-ctrl-z.plugin.zsh
parent2b499e1a9e8788d607768ecef67851e8234b72b3 (diff)
downloadzsh-08b04f5df2b9a4747b8f8975785bdcd523d85445.tar.gz
zsh-08b04f5df2b9a4747b8f8975785bdcd523d85445.tar.bz2
zsh-08b04f5df2b9a4747b8f8975785bdcd523d85445.zip
fancy-ctrl-z: ensure widgets are called with full context (#4838)
This allows other plugins that hook e.g. accept-line to identify the fancy-ctrl-z widget as the caller and take appropriate steps when necessary. See https://github.com/tarruda/zsh-autosuggestions/issues/82#issuecomment-181133379
Diffstat (limited to 'plugins/fancy-ctrl-z/fancy-ctrl-z.plugin.zsh')
-rw-r--r--plugins/fancy-ctrl-z/fancy-ctrl-z.plugin.zsh6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/fancy-ctrl-z/fancy-ctrl-z.plugin.zsh b/plugins/fancy-ctrl-z/fancy-ctrl-z.plugin.zsh
index 8ab297913..82b968894 100644
--- a/plugins/fancy-ctrl-z/fancy-ctrl-z.plugin.zsh
+++ b/plugins/fancy-ctrl-z/fancy-ctrl-z.plugin.zsh
@@ -1,10 +1,10 @@
fancy-ctrl-z () {
if [[ $#BUFFER -eq 0 ]]; then
BUFFER="fg"
- zle accept-line
+ zle accept-line -w
else
- zle push-input
- zle clear-screen
+ zle push-input -w
+ zle clear-screen -w
fi
}
zle -N fancy-ctrl-z