maintain compatibility

This commit is contained in:
Carlo Sala 2024-08-12 11:45:07 +02:00
commit 9af3d8f68a
No known key found for this signature in database
GPG key ID: DA6FB450C1A4FE9A
3 changed files with 17 additions and 10 deletions

View file

@ -9,9 +9,11 @@
function catimg() {
if [[ -x `which convert` ]]; then
zsh $ZSH/plugins/catimg/catimg.sh $@
if (( $+commands[magick] )); then
CONVERT_CMD="magick" zsh $ZSH/plugins/catimg/catimg.sh $@
elif (( $+commands[convert] )); then
CONVERT_CMD="convert" zsh $ZSH/plugins/catimg/catimg.sh $@
else
echo "catimg need convert (ImageMagick) to work)"
echo "catimg need magick/convert (ImageMagick) to work)"
fi
}