Skip to content

Instantly share code, notes, and snippets.

View anemitz's full-sized avatar

Anthony N anemitz

View GitHub Profile

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:

@thomasst
thomasst / migrate-redis.py
Created May 14, 2015 18:26
Migrate Redis data on Amazon ElastiCache
"""
Copies all keys from the source Redis host to the destination Redis host.
Useful to migrate Redis instances where commands like SLAVEOF and MIGRATE are
restricted (e.g. on Amazon ElastiCache).
The script scans through the keyspace of the given database number and uses
a pipeline of DUMP and RESTORE commands to migrate the keys.
Requires Redis 2.8.0 or higher.
@philfreo
philfreo / closeio_rest_api.php
Last active March 18, 2019 14:34
POST HTTP request with JSON in PHP
$lead = array('name' => 'test');
$headers = array('Content-Type' => 'application/json');
$options = array('auth' => array('YOUR_API_KEY', ''));
$request = Requests::post('https://api.close.com/api/v1/lead/', $headers, json_encode($lead), $options);