mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-25 10:03:03 +01:00
a9bfc2f55b
Signed-off-by: B. Watson <urchlay@slackware.uk> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
20 lines
270 B
Bash
20 lines
270 B
Bash
#!/bin/sh
|
|
|
|
src="$1"
|
|
shift
|
|
if [ -z "$src" -o ! -e "$src" -o "$*" ]; then
|
|
cat 1>&2 <<EOF
|
|
Usage: $0 /path/to/icon.png
|
|
EOF
|
|
fi
|
|
|
|
set -e
|
|
|
|
mkdir -p icons/
|
|
cat "$src" > icons/160.png
|
|
|
|
for i in 16 22 32 48 64 128; do
|
|
convert -resize ${i}x${i} "$src" icons/$i.png
|
|
done
|
|
|
|
exit 0
|