Skip to content

Instantly share code, notes, and snippets.

View ryanrhee's full-sized avatar

Ryan Rhee ryanrhee

View GitHub Profile
@ryanrhee
ryanrhee / screen_to_gif.sh
Created August 13, 2020 22:05
screen recording to gif
#!/bin/bash
# assumes the screen recording is pr.mov
# first, make a palette:
ffmpeg -y -i pr.mov -vf fps=10,palettegen palette.png
# use palette to make the gif (scaled to width:700)
ffmpeg -i pr.mov -i palette.png -filter_complex "fps=10,scale=700:-1,paletteuse" pr.gif