Skip to content

Instantly share code, notes, and snippets.

View a0viedo's full-sized avatar
🌯
no burrito no code

Alejandro Oviedo a0viedo

🌯
no burrito no code
View GitHub Profile

gif-from-tweet

There are so many great GIFs out there and I want to have copies of them. Twitter makes that harder than it should be by converting them to MP4 and not providing access to the source material. To make it easier, I made a bash pipeline that takes a tweet URL and a filename, extracts the MP4 from that tweet and uses ffmpeg to convert back to GIF.

Dependencies

  • ffmpeg
    • macOS: brew install ffmpeg
    • Ubuntu/Debian: apt install ffmpeg
@isaacs
isaacs / notes.md
Last active August 29, 2015 14:20

New approach:

  • spawn('sh', ...)

    Find the -c arg.

    Parse, and split up by && and || and | and ;, expanding each bit.

    Then spawn the exploded command line. When we explode it, we need to do the same thing with looking up env and shebang results.