summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/gencovers.sh9
1 files changed, 7 insertions, 2 deletions
diff --git a/tools/gencovers.sh b/tools/gencovers.sh
index 911a050..a0ec53d 100644
--- a/tools/gencovers.sh
+++ b/tools/gencovers.sh
@@ -2,12 +2,17 @@ for F in public/*/cover.jpg
do
echo Processing: $F
B=$(echo $F | sed s/.jpg//)
+ D=$(dirname $F)
- convert -scale 200x200 $F $B.1x.png
+ convert -resize 200x200 $F $B.1x.png
mozjpeg -q 95 -outfile $B.1x.jpg $B.1x.png
rm -f $B.1x.png
- convert -scale 400x400 $F $B.2x.png
+ convert -resize 400x400 $F $B.2x.png
mozjpeg -q 90 -outfile $B.2x.jpg $B.2x.png
rm -f $B.2x.png
+
+ convert -resize 108x144! $F $D/thumbnail.png
+ mozjpeg -q 90 -outfile $D/thumbnail.jpg $D/thumbnail.png
+ rm -f $D/thumbnail.png
done