mirror of
https://github.com/Llewellynvdm/nativefier.git
synced 2025-01-03 14:17:29 +00:00
Add check for imagemagick identify
This commit is contained in:
parent
ac2260c395
commit
459894cc2a
@ -10,15 +10,21 @@
|
||||
|
||||
# Exec Paths
|
||||
ICONUTIL=$(which iconutil)
|
||||
IMAGEMAGICK=$(which convert)
|
||||
IMAGEMAGICK_CONVERT=$(which convert)
|
||||
IMAGEMAGICK_IDENTIFY=$(which identify)
|
||||
|
||||
if [ ! -x "${ICONUTIL}" ]; then
|
||||
echo "Cannot find required iconutil executable" >&2
|
||||
exit 1;
|
||||
fi
|
||||
if [ ! -x "${IMAGEMAGICK}" ]; then
|
||||
if [ ! -x "${IMAGEMAGICK_CONVERT}" ]; then
|
||||
echo "Cannot find required ImageMagick Convert executable" >&2
|
||||
exit 1;
|
||||
fi
|
||||
if [ ! -x "${IMAGEMAGICK_IDENTIFY}" ]; then
|
||||
echo "Cannot find required ImageMagick Identify executable" >&2
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
# Parameters
|
||||
SOURCE=$1
|
||||
@ -90,7 +96,7 @@ convert "${SOURCE}" -define png:big-depth=16 -define png:color-type=6 -sample 10
|
||||
|
||||
|
||||
# Create an icns file lefrom the iconset
|
||||
iconutil -c icns "${ICONSET}" -o ${DEST}
|
||||
iconutil -c icns "${ICONSET}" -o "${DEST}"
|
||||
|
||||
# Clean up the iconset
|
||||
rm -rf "${ICONSET}"
|
||||
|
Loading…
Reference in New Issue
Block a user