Created
November 4, 2019 01:17
-
-
Save yutsuku/188e131df222e65374fc046945e1df44 to your computer and use it in GitHub Desktop.
sort digital camera photos and videos by date using exiftool
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# sort mp4 video files | |
exiftool -o . -P -progress -r -ext 'mp4' -if 'not $DateTimeOriginal' '-FileName<FileModifyDate' '-DateTimeOriginal<FileModifyDate' -d "%Y/%m/%Y%m%d-%H%M%S%%-c.%%e" . | |
# everything else | |
exiftool -o . -P -r '-FileName<DateTimeOriginal' '-FileCreateDate<DateTimeOriginal' -d "%Y/%m/%Y%m%d-%H%M%S%%-c.%%e" . |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment