#!/bin/bash # Script for converting an png image to 8bit semitransparent with dimension suitable for category icon if [ ! command -v convert >/dev/null 2>&1 ]; then >&2 echo "convert executable could not be found" exit 128 fi if [ "$1" = "" ]; then >&2 echo "zadej filename" exit 1 fi filename="$1" mkdir -p ./cat convert "$filename" -channel A -evaluate Multiply 0.9 +channel -resize 48x64 "cat/$filename"