Skip to content

Instantly share code, notes, and snippets.

@zeke
Forked from jclem/gifify.sh
Created February 7, 2013 20:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zeke/4734063 to your computer and use it in GitHub Desktop.
Save zeke/4734063 to your computer and use it in GitHub Desktop.
if [ "$#" -lt 1 ]; then
echo 'Must supply an input file'
exit 1
else
if [ "$#" -lt 2 ]; then
output=output
else
output=$2
fi
# Convert it to a .gif
ffmpeg -i $1 -pix_fmt rgb24 -r 10 ${output}.gif
# Compress it
convert -layers Optimize ${output}.gif ${output}.gif
# Send it to CloudApp
cloudapp -d $h{output}.gif
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment