Skip to content

Instantly share code, notes, and snippets.

@insertish
Created February 12, 2022 15:06
Show Gist options
  • Save insertish/6ec669af3d534051a8f16ebdfecacc18 to your computer and use it in GitHub Desktop.
Save insertish/6ec669af3d534051a8f16ebdfecacc18 to your computer and use it in GitHub Desktop.
Combine all video files in a directory into one.
ls -w 1 > list && sed -i -e 's/^list$//' list && sed -i -e 's/^\(.\+\)$/file \'\1\'/' list && cat list && ffmpeg -f concat -safe 0 -i list -c copy output.mp4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment