I have a bunch of pictures that I want to print, but in order for them to print out correctly every other picture needs to be flipped horizontally. Now, the pictures are all png files and are labeled "Foo 001.png"
, "Foo 002.png"
. I am thinking that all I need to do is look at the part of the string that has the number, convert it to an integer, do n%2==0
to check if it is even, and flip it if it is even.
I don't know if there is a convenient way to convert from a string to an integer using bash or what I would use to flip the picture.