Changing file create / modify date from EXIf data

Started by marcjb, February 07, 2021, 02:04:30 PM

Previous topic - Next topic

marcjb

Hello,

I am a Mac user with an Android phone. The usual problem is that when I import photos or videos, Mac OS fills the created and modified date with the date the photos or movies were imported, not when they were taken.
I would like to change both to the correct time and date they were taken as stored in the exif info.
I have searched this forum high and low but none of the solutions work -- the setFile command is for windows only, I worked out, and I found somewhere this:

exiftool '-datetimeoriginal<MDItemFSCreationDate' -overwrite_original_in_place -P *.*

But doing this (when in the directory) does not seem to work: Exif tool reports back that it updated the files, but going into the finder reveals exactly the same dates as before....
Sorry if that has been answered before, but what do I need to do?

StarGeek

#1
Quote from: marcjb on February 07, 2021, 02:04:30 PM
I have searched this forum high and low but none of the solutions work -- the setFile command is for windows only, I worked out,

SetFile is for Mac OS, not Windows.  See here on how to install it.

Quoteexiftool '-datetimeoriginal<MDItemFSCreationDate' -overwrite_original_in_place -P *.*

But doing this (when in the directory) does not seem to work: Exif tool reports back that it updated the files

That would probably do the reverse of what you want.  That sets the EXIF date from the Mac's MD (file system?) creation date.

After you install SetFile, try this.  Use a dot . to indicate the current directory (see Common Mistake #2)
exiftool '-FileCreateDate<DateTimeOriginal' '-FileModifyDate<DateTimeOriginal' /path/to/files/
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

Phil Harvey

Quote from: StarGeek on February 07, 2021, 02:17:26 PM
exiftool  -P '-FileCreateDate<DateTimeOriginal' '-FileModifyDate<DateTimeOriginal' /path/to/files/

Why the -P ?

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

StarGeek

"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

Phil Harvey

...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).