Update chatgpt.sh

Add support for kitty icat image preview on kitty terminal.
pull/59/head
Rex Ackermann 1 year ago committed by GitHub
parent a6f6c20022
commit 3860335207
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      chatgpt.sh

@ -255,6 +255,10 @@ while $running; do
curl -sS $image_url -o temp_image.png
imgcat temp_image.png
rm temp_image.png
elif [[ "$TERM" == "xterm-kitty" ]]; then
curl -sS $image_url -o temp_image.png
kitty +kitten icat temp_image.png
rm temp_image.png
else
echo "Would you like to open it? (Yes/No)"
read -e answer

Loading…
Cancel
Save