From d85c23c433cd5ff07fc5a1d5210d1d63a608a572 Mon Sep 17 00:00:00 2001 From: Daniel Bretoi Date: Thu, 12 Sep 2024 22:15:18 -0700 Subject: [PATCH] Update preview-tui make NNN_PREVIEWIMGPROG flexible enough to accept any program. programs like `timg` would also work (my preference), but it seems odd to add every single program out there when it's easy to add new ones by just this one variable --- plugins/preview-tui | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/preview-tui b/plugins/preview-tui index 860a93a0..200d3e33 100755 --- a/plugins/preview-tui +++ b/plugins/preview-tui @@ -460,6 +460,8 @@ image_preview() { chafa "$3" & elif exists img2sixel && [[ "$NNN_PREVIEWIMGPROG" == +(|img2sixel) ]]; then img2sixel -g "$3" & + elif exists "$NNN_PREVIEWIMGPROG"; then + "$NNN_PREVIEWIMGPROG" "$3" & else fifo_pager print_bin_info "$3" && return fi