Skip to content

Commit

Permalink
Merge pull request jarun#1456 from luukvbaal/preview-tui
Browse files Browse the repository at this point in the history
Preview-tui fix image_preview stdout
  • Loading branch information
jarun authored Aug 7, 2022
2 parents a335f94 + 95e1d56 commit ad62463
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/preview-tui
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,6 @@ generate_preview() {
printf "%s" "$!" > "$PREVIEWPID"
return
else
exec >/dev/tty
image_preview "$1" "$2" "$3"
return
fi ;;
Expand All @@ -405,6 +404,7 @@ generate_preview() {

image_preview() {
clear
exec >/dev/tty
if [ "$TERMINAL" = "kitty" ]; then
# Kitty terminal users can use the native image preview method
kitty +kitten icat --silent --scale-up --place "$1"x"$2"@0x0 --transfer-mode=stream --stdin=no "$3" &
Expand Down

0 comments on commit ad62463

Please sign in to comment.