I have long .wav files that I wish to split into separate files of exactly 60 minutes each, using ffmpeg. I am using ffmpeg from the terminal in Mac OS X. If a bash or other shell script is necessary to solve my issue, that is okay.
From this question, I use the following
ffmpeg -i input.wav -f segment -segment_time 3600 output_%03d.wav
However, each file has a file creation date and time for when I execute the split segment command above. I would like the files to have creation dates and times based on creation time of the original file. From this question, I know I can use ffprobe to get the creation information. For example,
ffprobe -v quiet input.wav -show_entries stream_tags:format_tags
might show
TAG:date=2025-09-18
TAG:creation_time=22:24:54
Is it possible to include this information in the newly created split files? The first file output_000.wav should have the same creation date and time as the original file. Subsequent files (e.g., output_001, output_002, etc) should have creation times exactly 60 minutes after the previous file. From the example above, output_000 should have a creation time of 22:24:54. output_001 should have a creation_time of 23:24:54, etc. The last file may not be 60 minutes long. For example, a file that is 130 minutes long would have two files of 60 minutes each and a final file of 10 minutes.
Note that the original files typically start at night and can go past midnight to the next morning, so that would need to be accounted for.
PS: I've seen this answer but that overlays text on a video file. I can't figure out how to adapt it to my question.
-metadata. It can't be copied from the input, because you want to modify it. doing this correctly in a shell environment is complex, do it in the consuming end instead.