Rotate Image (Script) without changing "modified" date
Hello everyone, Joe Newbie here. Welcome to my first script; well sorta. I am actually modifying someone else's script and I need some help. The original script rotated image files to the left but it changed the "modified date stamp" which is something I didn't want.
Code:
#!/bin/bash I've done batch files in DOS years ago so there are a lot of similarities of course. And I'm not looking for someone to just fix this for me but to also explain to me what I'm doing that is causing the incorrect behavior. Is there a more elegant way of doing this? And BTW, it actually does what I'm asking it to do but only when I do something I consider quite odd. 1) I right click on the .jpg and select rotate left. 2) The file responds by flipping 180 degrees 'instead' of 90 degree counter clockwise. 3) I refresh the file manager and nothing happens. 4) I 'touch" the file with my pointer (it doesn't matter if I "touch" it with a left or a right mouse click) and it correctly orients itself. It's important to note that the original script, before I made any edits, did not have this quirk whereas I needed to "touch" the file to get it to orient itself correctly. The 'original' script is in black; my additions are in blue. Thanks, |
It is not clear where the problem is, since the command
Code:
jhead -ft "$1" |
Quote:
2) The file responds by flipping 180 degrees 'instead' of 90 degree counter clockwise. 3) I refresh the file manager and nothing happens. 4) I 'touch" the file with my pointer (it doesn't matter if I "touch" it with a left or a right mouse click) and it correctly orients itself. |
All times are GMT -5. The time now is 11:28 AM. |