Skip to content

Instantly share code, notes, and snippets.

@auermi
Last active March 28, 2021 21:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save auermi/6baa370ea4cbf598cf3644e50a0b5a90 to your computer and use it in GitHub Desktop.
Save auermi/6baa370ea4cbf598cf3644e50a0b5a90 to your computer and use it in GitHub Desktop.
Copy one file's metadata to another with the same name in the current directory
# Works even if <datetimeoriginal does not exist on certain files
# Check tags of a file
exiftool -g1 -a -s video.MPG
# AVI to MP4
exiftool -TagsFromFile %d%f.AVI "-FileModifyDate" -ext mp4 .
# MPG to MP4
exiftool -TagsFromFile %d%f.MPG "-FileModifyDate" -ext mp4 .
# Oneoff change date
touch -mt 200711040000 2588.mp4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment