I am new to Scripting but I am trying to write a Hazel script that will compare an image height, and an image width, and if they match (because the image is square) I'd like to return true so I can perform actions. This is my attempt to sort out any Instagram photos I have pushed to my computer.
Was working with something like this:
set imageFile to file theFile
tell application "Image Events"
set my_image to open imageFile
set my_dimensions to dimensions of my_image
set my_x to item 1 of my_dimensions as integer
set my_y to item 2 of my_dimensions as integer
if my_x is my_y then true
But this may be complete wrong.
Let me know if someone can help.