Exif date manipulation

Modifiy dates of media files (jpg) in current folder

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

Modifiy dates for mp4 files

mp4 files in my case has no tag DateTimeOriginal

find -name '*.mp4' | while read PIC; do
    DATE=$(exiftool -p '$CreateDate' $PIC |
    sed 's/[: ]//g')
    touch -t $(echo $DATE | sed 's/\(..$\)/\.\1/') $PIC
done

Nextcloud reindex for proper visibility

  sudo -u nginx php occ files:scan <path>/Camera <user>