From 3ea99a2c727fadab44e3a71ba44af8a8e0d54d80 Mon Sep 17 00:00:00 2001 From: Alessandro Bernardello <53372753+alessandroberna@users.noreply.github.com> Date: Thu, 6 Jun 2024 23:17:29 +0200 Subject: [PATCH] convert deprecation workaround --- lsix | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lsix b/lsix index 2d6adc3..7e30354 100755 --- a/lsix +++ b/lsix @@ -68,7 +68,12 @@ fi if [[ "$COMSPEC" ]]; then alias convert="magick convert" # Shun MS Windows' "convert" command. fi - + +# convert has been deprecated with ImageMagick 7 +if [ "$(identify -version | head -n 1 | awk '{print $3}' | cut -d'.' -f1)" -ge 7 ]; then + alias convert="magick" +fi + cleanup() { echo -n $'\e\\' # Escape sequence to stop SIXEL. stty echo # Reset terminal to show characters.