diff options
Diffstat (limited to 'update_images')
-rwxr-xr-x | update_images | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/update_images b/update_images new file mode 100755 index 0000000..fd8f8fa --- /dev/null +++ b/update_images @@ -0,0 +1,15 @@ +#!/bin/bash +# +# Update pictures, +# recursively remove metadata and decrease file size, +# for each pictures + +IMG_DIR="static/images" +IMG_LIST=$(find ${IMG_DIR}) +IMG_MAX_SIZE="250k" + +for img in ${IMG_LIST[@]}; do + jhead -purejpg "${img}" + jpegoptim --size "${IMG_MAX_SIZE}" "${img}" +done + |