Created
July 29, 2016 14:02
-
-
Save brian-i/059bce5b9aaa9d59494d1faff93c7b25 to your computer and use it in GitHub Desktop.
Batch Image Straightening and Corrections
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Uses http://www.imagemagick.org | |
# Astoria LIC | |
find . -name "*.tif" | while read file; do | |
convert "$file" -background '#fdfdfd' -rotate 5 rotated_"${file:2}" | |
convert rotated_"${file:2}" -bordercolor '#fdfdfd' -border 40x100 rotbor_"${file:2}" | |
sh multicrop2 -f 10 -u 2 rotbor_"${file:2}" pro_"${file:2}" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment