Skip to content

Instantly share code, notes, and snippets.

@dergachev
dergachev / GIF-Screencast-OSX.md
Last active May 2, 2024 05:55
OS X Screencast to animated GIF

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application:

// Includes functions for exporting active sheet or all sheets as JSON object (also Python object syntax compatible).
// Tweak the makePrettyJSON_ function to customize what kind of JSON to export.
var FORMAT_ONELINE = 'One-line';
var FORMAT_MULTILINE = 'Multi-line';
var FORMAT_PRETTY = 'Pretty';
var LANGUAGE_JS = 'JavaScript';
var LANGUAGE_PYTHON = 'Python';
@mjackson
mjackson / mockstream.js
Created September 7, 2011 17:31
A mock stream wrapper for node.js
var util = require("util"),
Stream = require("stream").Stream;
module.exports = MockStream;
/**
* A constructor that inherits from Stream and emits data from the given
* `source`. If it's a Stream it will be piped through to this stream.
* Otherwise, it should be a string or a Buffer which will be emitted by this
* stream as soon as possible.