Bash - change file timestamps using exif data

Bash - change file timestamps using exif data

Bash - change file timestamps using exif data

find . -type f | while read PIC
do
     DATE=$(exiftool -p '$DateTimeOriginal' $PIC | sed 's/[: ]//g')
     touch -t $(echo $DATE | sed 's/\(..$\)/\.\1/') $PIC
done