Set date on all your JPG photos from EXIF data

I don’t know if it’s a normal situation or it is one of that things that only happens to me: All my photos had lost their original timestamp. So all files have the same date (the date when files were copied from the old hard disk) and it’s a mess when you have gigs of photos from travels, family, events, animals, etc. without its original shoot date.

So I adapted this little script that reads EXIF data from JPGs recursively into folders and sets timestamp on the files accordingly. Easy!

All you need is the exiv2 tool (quickly available on your distro repos) and run this little script: (Remember to chmod it to a+x or 755).