Skip to content

Instantly share code, notes, and snippets.

@attilaolah
Created April 30, 2022 11:36
Show Gist options
  • Save attilaolah/fc10799f7215b15b99cc21ddb656675b to your computer and use it in GitHub Desktop.
Save attilaolah/fc10799f7215b15b99cc21ddb656675b to your computer and use it in GitHub Desktop.
Fix SONY ARW timestamps (after forgetting to change time zone)
# Fix time offset:
export TZ=GMT+2
$ exiftool '-FileModifyDate<${SonyDateTime2}+00:00' .
$ exiftool '-CreateDate<${FileModifyDate}' '-ModifyDate<${FileModifyDate}' '-DateTimeOriginal<${FileModifyDate}' '-SonyDateTime<${FileModifyDate}'
# Geotag using UTC timestamps:
$ for gpx in *.gpx; exiftool -geotag "${gpx}" '-Geotime<${SonyDateTime2}+00:00' .
# Clean up:
$ exiftool -delete_original .
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment