Skip to content

Instantly share code, notes, and snippets.

@eriky
Last active December 23, 2019 11:06
Show Gist options
  • Save eriky/f15e2c54f9d08460419be529139fd04b to your computer and use it in GitHub Desktop.
Save eriky/f15e2c54f9d08460419be529139fd04b to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash
set -e -x
if [ "$1" == "" ] || [ "$2" == "" ]; then
echo "Usage:"
echo "$0 <input directory> <output directory>"
exit
fi
for video in `ls $1`; do
ffmpeg -i "$1/$video" -c:v libx265 -c:a aac -b:a 128k "$2/$video".mp4
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment