First create a text files that looks like this:
00:00:58 00:01:21
00:05:43 00:06:27
00:08:03 00:09:37
00:10:03 00:11:22
00:13:06 00:13:30
In each line write the start time and end time of the parts that you want to cut.
Then make sure the script is executable:
$ chmod +x cut-parts.sh
And then run the script:
$ ./cut-parts.sh input.mp4 times.txt ./parts-folder
- The first argument is the address of the video file.
- The second argument is the address of the text file which contains the parts' times.
- The third argument is the address of a directory which the parts' files will be created in.