Skip to content

Instantly share code, notes, and snippets.

@kramfs
Created December 17, 2021 05:31
Show Gist options
  • Save kramfs/a05f73a512462bd8e7a522e6afcbbba2 to your computer and use it in GitHub Desktop.
Save kramfs/a05f73a512462bd8e7a522e6afcbbba2 to your computer and use it in GitHub Desktop.
Resize image aspect ratio in MacOS CLI using sips
# This will resize the image to 514x400 pixels. Height: 514 (pixel) x Width: 400 (pixel).
# This is good for forms that require certain image aspect ratio i.e. passport, license, etc
# NOTE: Make a copy of the original image as a backup just in case.
sips --resampleHeightWidth 514 400 Passport_Photo_copy.jpg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment