Skip to content

Instantly share code, notes, and snippets.

@tjibbevanderlaan
Last active February 8, 2020 22:00
Show Gist options
  • Save tjibbevanderlaan/73be8e3e7d9f692231eb944d35f18d27 to your computer and use it in GitHub Desktop.
Save tjibbevanderlaan/73be8e3e7d9f692231eb944d35f18d27 to your computer and use it in GitHub Desktop.
Add GPS exif-data to all photos in directory with exiftool
#/bin/sh
PHOTODIR=$1
LATITUDE=$2
LONGITUDE=$3
LATREF=${4:-N}
LONGREF=${5:-E}
exiftool $PHOTODIR -GPSLongitudeRef=$LONGREF -GPSLongitude=$LONGITUDE -GPSLatitudeRef=$LATREF -GPSLatitude=$LATITUDE
exiftool $PHOTODIR "-GPSDateStamp<CreateDate" -globalTimeShift
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment