Add script
This commit is contained in:
parent
4a3ec4bb03
commit
f4e3041cb9
1 changed files with 19 additions and 0 deletions
19
smallpictures.sh
Executable file
19
smallpictures.sh
Executable file
|
@ -0,0 +1,19 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [ ! -d "small" ]
|
||||||
|
then
|
||||||
|
echo "Create dir *small/*"
|
||||||
|
mkdir -p "small"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Convert pictures to preview and bigger version..."
|
||||||
|
for i in *.$1; do
|
||||||
|
magick $i -quality 50% -resize '800x800' small/${i%.$1}-preview.$1;
|
||||||
|
magick $i -quality 88% -resize '4096x4096' small/$i;
|
||||||
|
|
||||||
|
done
|
||||||
|
|
||||||
|
echo "Delete metadata..."
|
||||||
|
exiftool -all= -overwrite_original small/*
|
||||||
|
|
||||||
|
echo "Done!"
|
Loading…
Reference in a new issue