Skip to content

Instantly share code, notes, and snippets.

@yanxurui
Created April 19, 2018 06:21
Show Gist options
  • Save yanxurui/43532410fac925ac9dc067506b7748a5 to your computer and use it in GitHub Desktop.
Save yanxurui/43532410fac925ac9dc067506b7748a5 to your computer and use it in GitHub Desktop.
convert vdat to mp4
set -x
src="/Users/yxr/Downloads/in/"
for fullfile in "$src"*.vdat
do
filename="${fullfile##*/}"
output="/Users/yxr/Downloads/out/${filename%.*}.mp4"
echo $output
ffmpeg -i "$fullfile" -codec copy "$output"
done
@yanxurui
Copy link
Author

tips

  • loop files(ls doesn't work when space exists in the filename)
  • change extension of filename
  • transcode by ffmpeg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment