Skip to content

Instantly share code, notes, and snippets.

@DiogenesAnalytics
Created February 22, 2024 21:20
Show Gist options
  • Save DiogenesAnalytics/a6834b3cc8d07d2faa5d3fb611dfe388 to your computer and use it in GitHub Desktop.
Save DiogenesAnalytics/a6834b3cc8d07d2faa5d3fb611dfe388 to your computer and use it in GitHub Desktop.
Converting all .webm to .mp4 using ffmpeg
for file in *.webm; do
# Generate output file name with mp4 extension
output_file="${file%.webm}.mp4"
# Convert webm to mp4 using ffmpeg, re-encoding the streams
ffmpeg -i "$file" -c:v libx264 -c:a aac "$output_file"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment