nnn

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit c48691fe3d1e43e92937a6a3f6e28a1469b4684e
parent fa7c19c4097bfb71eef16060724c5bd8da424a9e
Author: Luuk van Baal <luukvbaal@gmail.com>
Date:   Mon,  4 Oct 2021 00:12:48 +0200

Change preview-tui winch workaround

Diffstat:
Mplugins/preview-tui | 10+++++++---
1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/plugins/preview-tui b/plugins/preview-tui @@ -378,6 +378,13 @@ ueberzug_remove() { } winch_handler() { + # workaround for preview-tui tmux child causing zombie pane + if [ "$NNN_PARENT" -eq "$NNN_PARENT" ] 2>/dev/null; then + kill -0 "$NNN_PARENT" || return + else + pidof nnn || return + fi + clear kill "$(cat "$PREVIEWPID")" if [ -p "$FIFO_UEBERZUG" ]; then @@ -385,9 +392,6 @@ winch_handler() { tail --follow "$FIFO_UEBERZUG" | ueberzug layer --silent --parser json & fi preview_file "$(cat "$CURSEL")" - if ! kill -0 "$NNN_PARENT" || ! pgrep nnn >/dev/null; then - pkill -P "$$" - fi } 2>/dev/null preview_fifo() {