From d827723309c554dee0e1109383a0ad3006227f5b Mon Sep 17 00:00:00 2001 From: Colin Clark Date: Thu, 30 Jan 2025 16:50:04 +0000 Subject: [PATCH] Fix #1592: Won't try using exiv2 https://github.com/BestImageViewer/geeqie/issues/1592 exiftool is no longer used in the image crop script - exiv2 replaces the function exiftool performed. --- plugins/image-crop/geeqie-image-crop | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/plugins/image-crop/geeqie-image-crop b/plugins/image-crop/geeqie-image-crop index 19ac4886..06e43084 100755 --- a/plugins/image-crop/geeqie-image-crop +++ b/plugins/image-crop/geeqie-image-crop @@ -3,7 +3,7 @@ ## @file ## @brief Crop image ## -## Requires ImageMagick and exiftool +## Requires ImageMagick and exiv2 ## Crops the image to the size set by the Draw Rectangle menu item ## @@ -21,10 +21,10 @@ process_raw () src_filename=$(ls "$tmpdir/") filename="${src_filename%.*}" extension="${src_filename##*.}" - rotation=$(exiftool -Orientation -n "$1" | cut -d':' -f2 | xargs) + rotation=$(exiv2 -g Exif.Image.Orientation -Pv "$1") convert "$tmpdir/$src_filename" -crop "$2" "$tmpdir/$filename-crop.$extension" - exiftool -Orientation="$rotation" -n "$tmpdir/$filename-crop.$extension" + exiv2 -M"set Exif.Image.Orientation $rotation" "$tmpdir/$filename-crop.$extension" rm "$tmpdir/$src_filename" @@ -58,7 +58,7 @@ export title="Geeqie crop image" if [ -x "$(command -v convert)" ] then - if [ -x "$(command -v exiftool)" ] + if [ -x "$(command -v exiv2)" ] then coords=$(geeqie --get-rectangle) @@ -94,7 +94,7 @@ then fi fi else - zenity --info --title="$title" --text="Crop image\n\nexiftool is not installed" --title="$title" --window-icon="$window_icon" 2> /dev/null + zenity --info --title="$title" --text="Crop image\n\nexiv2 is not installed" --title="$title" --window-icon="$window_icon" 2> /dev/null exit 0 fi else