commit 06bf4f5dce81367eccf3f9b3611b4d05aee2953a parent 3be2dd839060f49ba506289a26aab96b542c3d1e Author: Luuk van Baal <luukvbaal@gmail.com> Date: Tue, 14 Dec 2021 17:16:56 +0100 Replace restorepreview workaround Diffstat:
| M | patches/restorepreview/mainline.diff | | | 7 | +++++-- |
| M | plugins/preview-tui | | | 2 | +- |
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/patches/restorepreview/mainline.diff b/patches/restorepreview/mainline.diff @@ -1,5 +1,8 @@ -# Description: Adds preview pipe to enable closing and re-opening -# the preview pane when running an undetached editor. +# Description: Adds preview pipe to enable closing and re-opening the preview +# pane when running an undetached editor. If you are using vim +# you might experience incorrectly resized window. Consider adding +# the following to your vimrc: +# autocmd VimEnter * :silent exec "!kill -s WINCH $PPID" # # Authors: Luuk van Baal diff --git a/plugins/preview-tui b/plugins/preview-tui @@ -415,7 +415,7 @@ preview_fifo() { if [ -n "$selection" ]; then kill "$(cat "$PREVIEWPID")" [ -p "$FIFO_UEBERZUG" ] && ueberzug_remove - [ "$selection" = "close" ] && sleep 0.15 && pkill -P "$$" && exit + [ "$selection" = "close" ] && break preview_file "$selection" printf "%s" "$selection" > "$CURSEL" fi