JPG: remove all metadata except IFD0 + original date and time

Started by da1k, October 18, 2021, 03:00:39 PM

Previous topic - Next topic

da1k

Hello,

How can I remove from JPG files all metadata except IFD0 part (orientation, author, subject etc) and DateTimeOrginal and CreateDate from ExifIFD section?

StarGeek

Try
exiftool -ext jpg -all= -TagsFromFile @ -IFD0:all -DateTimeOriginal -CreateDate /path/to/files/

Edit: Fixed typo
"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

da1k

It's almost perfect. It keeps original date and time but removes subject and author which I wish to have. Rest metadata is gone :)

EDIT: I found how to do it :)

exiftool -ext jpg -all= -TagsFromFile @ -IDF0:all -XPSubject -XPAuthor -Copyright -Artist -DateTimeOriginal -CreateDate -ColorSpace /path/to/files/
do the job :)

@StarGeek thank you very much for help :)

best regards,
da1k

StarGeek

Ooops, typo on my part.  Change
-IDF0:all
into
-IFD0:all

Of course, you can always copy individual tags as you found out.
"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