Skip to content

Instantly share code, notes, and snippets.

@takayukioda
Last active June 3, 2019 09:36
Show Gist options
  • Select an option

  • Save takayukioda/71ea3da1308f9488cb7005363280527f to your computer and use it in GitHub Desktop.

Select an option

Save takayukioda/71ea3da1308f9488cb7005363280527f to your computer and use it in GitHub Desktop.
#!/bin/bash +x
[ $# -lt 2 ] && echo "Usage: $(basename $0) <input path> <output filename>" >&2 && exit 1
input_path=$1
output_filename=$2
input_dirname=$(cd $(dirname "$input_path") && pwd -P)
ffmpeg -i "$input_path" -vf fps=10,scale=640:-1 "$input_dirname/$output_filename.gif"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment