Skip to content

Instantly share code, notes, and snippets.

package main
import (
"bufio"
"flag"
"fmt"
"io"
"os"
"path/filepath"
"regexp"
#! /usr/bin/python3
# create a gif from a video using ffmpeg and imagemagick.
# both ffmpeg and imagemagick must be installed and added to the PATH env variable for this to work.
# if I were being fancier, I'd make this take command line arguments instead of just setting
# variables inside the `if __name__ == '__main__'` block, but it's intended for personal use only
# so whatever.
import os
import subprocess