ExifTool Forum

ExifTool => The "exiftool" Application => Topic started by: chelmite on July 03, 2016, 11:08:16 AM

Title: case for overwriting files
Post by: chelmite on July 03, 2016, 11:08:16 AM
I used exiftool to adjust the times in some new files and copy them to a directory with the creation date:
exiftool -P '-Directory</local/home/me/Pictures/${DateTimeOriginal}' -d '%Y/%m/%d'
exiftool dutifully copied my files.

But now I realize that I want to do the same operation again, on the same original files, but add an author tag, replacing the files that I just copied by date.

When I try this, exiftool complains that the destination files already exist. Yes, I know, it's possible I could be destroying some other files with exactly the same names, but I just wrote them and I want to install the correct version of hundreds of files. It will be a pain to try to find each of these files and delete them to make room for the new version that has the Author tag.

I understand the need for protecting users from stupid mistakes (and I've made more than my share using exiftool!), but, at least in this case, I know which files I want to overwrite, but it's really difficult to undo the last exiftool filing step that I did.
Title: Re: case for overwriting files
Post by: Phil Harvey on July 04, 2016, 06:35:32 PM
Let me think about this a while.

- Phil
Title: Re: case for overwriting files
Post by: StarGeek on July 05, 2016, 04:10:44 PM
Quote from: chelmite on July 03, 2016, 11:08:16 AM
I used exiftool to adjust the times in some new files and copy them to a directory with the creation date:
exiftool -P '-Directory</local/home/me/Pictures/${DateTimeOriginal}' -d '%Y/%m/%d'
exiftool dutifully copied my files.

I assume that you forgot the -o option?  Because that command moves files and you wouldn't be able to perform the same operation again.
Title: Re: case for overwriting files
Post by: Phil Harvey on December 09, 2020, 09:46:21 AM
It's been a few years, and not enough people have complained about this to warrant adding such a dangerous feature as this.

- Phil