Skip to content

Instantly share code, notes, and snippets.

@ricloy
ricloy / rotate_and_crop_pictures.sh
Created May 24, 2023 11:51
Bash script that rotates and crops pictures inside directory using ImageMagick and some basic trigonometry
# input directory
DIR=/full/path
# angle of rotation in degrees
angle=
# output directory
output_dir="$DIR"_rotated_cropped
# create output dir if it doesn't exist