Skip to content

Instantly share code, notes, and snippets.

@hernamesbarbara
Created December 10, 2021 01:47
Show Gist options
  • Save hernamesbarbara/2b2d368dd4240fe9a2d1cfc898c6898d to your computer and use it in GitHub Desktop.
Save hernamesbarbara/2b2d368dd4240fe9a2d1cfc898c6898d to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash
# -*- coding: utf-8 -*-
filename=$(basename -- "$1")
extension="${filename##*.}"
filename="${filename%.*}"
ffmpeg -i "$1" \
-vf scale=-1:720\
-c:v libx264\
-crf 18 \
-preset veryslow \
-c:a copy \
"$filename".mp4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment