Author Topic: ExifTool and Terminal virgin on Mac OSX  (Read 2802 times)

Benson

  • Newbie
  • *
  • Posts: 4
ExifTool and Terminal virgin on Mac OSX
« on: November 01, 2013, 02:20:37 AM »
Hi,

Looked but can't find basic instructions on how one goes about changing the created date of a .MOV and a .tif file to a date in the past?
Any tips greatly appreciated.

Phil Harvey

  • ExifTool Author
  • Administrator
  • ExifTool Freak
  • *****
  • Posts: 16687
    • ExifTool Home Page
Re: ExifTool and Terminal virgin on Mac OSX
« Reply #1 on: November 01, 2013, 07:17:31 AM »
Are you talking about the filesystem date, or one stored in the metadata of the file?  And what system are you using?

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

Benson

  • Newbie
  • *
  • Posts: 4
Re: ExifTool and Terminal virgin on Mac OSX
« Reply #2 on: November 03, 2013, 08:15:45 AM »
Hi Phil,

Not sure what the filesystem date is but would it not be wise to have both match if one is going to the trouble of changing either one?
On Mac OSx 10.6.8

Phil Harvey

  • ExifTool Author
  • Administrator
  • ExifTool Freak
  • *****
  • Posts: 16687
    • ExifTool Home Page
Re: ExifTool and Terminal virgin on Mac OSX
« Reply #3 on: November 03, 2013, 09:33:04 AM »
For changing common metadata dates in JPG or TIFF images, the AllDates tags is useful:

exiftool -alldates="2000:01:02 03:04:05" image.tiff

This sets DateTimeOriginal, CreateDate and ModifyDate.  Add this to the command to also set the filesystem modification date the Finder "Modified" date:

-filemodifydate="2000:01:02 03:04:05"

You can't currently set the filesystem creation date using ExifTool.  See the Extra tags documentation for more information.

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

Benson

  • Newbie
  • *
  • Posts: 4
Re: ExifTool and Terminal virgin on Mac OSX
« Reply #4 on: November 03, 2013, 04:34:49 PM »
Hi Phil,

Thanks for that.
So I launch Terminal and write "exiftool -alldates="2000:01:02 03:04:05" image.tiff" to change the metadata date for when a jpeg or tiff was captured/created?
How does Terminal know which file I'm referring to and what about .MOV files?

Ben

Phil Harvey

  • ExifTool Author
  • Administrator
  • ExifTool Freak
  • *****
  • Posts: 16687
    • ExifTool Home Page
Re: ExifTool and Terminal virgin on Mac OSX
« Reply #5 on: November 04, 2013, 07:04:46 AM »
Hi Ben,

Instead of typing "image.tiff", either type in the full path name of your file, or drag and drop the image onto the Terminal window to have Terminal type it for you.  "image.tiff" was just an example.

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

Benson

  • Newbie
  • *
  • Posts: 4
Re: ExifTool and Terminal virgin on Mac OSX
« Reply #6 on: November 06, 2013, 01:14:58 PM »
Thanks Phil and this works with .MOV files too?

Phil Harvey

  • ExifTool Author
  • Administrator
  • ExifTool Freak
  • *****
  • Posts: 16687
    • ExifTool Home Page
Re: ExifTool and Terminal virgin on Mac OSX
« Reply #7 on: November 06, 2013, 02:36:54 PM »
Hi Ben,

Sorry, I missed answering this question.

I'm currently working on adding the ability to write MOV videos, so give me a couple of days.  The next release should have this feature.  But for MOV, the -alldates shortcut won't cover all of the embedded date/time tags, so you will have to add any others to your command line.  Or, with a new feature of the next release, you may do this with the following:

exiftool -time:all="2000:01:02 03:04:05" -wm w FILE

where FILE is one or more file and/or directory names.

This command won't work for ExifTool 9.39 or earlier because 9.40 will add the ability to write all date/time tags with -time:all= (as well as the ability to write MOV files).  The -wm w prevents ExifTool from creating new tags.

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