DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

Cover image for Batch processing video with FFmpeg
Sergey Fedotov
Sergey Fedotov

Posted on

Batch processing video with FFmpeg

Sometimes need to compress a few videos quickly, but few services allow you to do that or you don’t want to use them at all to save time or your privacy.

Then you might want to consider FFmpeg and a slick trick in the terminal:

mkdir res; for i in *.mov; do ffmpeg -i $i ./res/${i%.*}.mov; done

  1. mkdir res β€” will created a folder for processed videos
  2. in *.mov β€” is responsible for the file extension on the input
  3. ${i%.*}.mov β€” indicates the file extension of the output

Latest comments (0)

Build Anything...


Use any Linode offering to create something for the DEV x Linode Hackathon 2022. A variety of prizes are up for grabs, inculding $1,000 USD. πŸ‘€

β†’ Join the Hackathon <-