This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
#!/bin/sh | |
set -e | |
HOST=localhost | |
DB=test-entd-products | |
COL=asimproducts | |
S3PATH="s3://mongodb-backups-test1-entd/$DB/$COL/" | |
S3BACKUP=$S3PATH`date +"%Y%m%d_%H%M%S"`.dump.gz | |
S3LATEST=$S3PATH"latest".dump.gz | |
/usr/bin/aws s3 mb $S3PATH |
var mgo = new Mongo() | |
function getReadableFileSizeString(fileSizeInBytes) { | |
var i = -1; | |
var byteUnits = [' kB', ' MB', ' GB', ' TB', 'PB', 'EB', 'ZB', 'YB']; | |
do { | |
fileSizeInBytes = fileSizeInBytes / 1024; | |
i++; | |
} while (fileSizeInBytes > 1024); |
// ==UserScript== | |
// @name AWS title changer | |
// @description Change page title on AWS Management Console | |
// @namespace dev.sheile.net | |
// @include https://console.aws.amazon.com/* | |
// @include https://*.console.aws.amazon.com/* | |
// @version 1 | |
// ==/UserScript== | |
(function() { | |
var SERVICE_NAMES = { |
#!/usr/bin/env bash | |
# | |
# Example of multiple key AES encryption for text files using the openssl v. 0.9.8+ command line utility | |
# Uses n public certs as key for MIME PKCS envelope, any individual private key can decrypt. | |
# | |
# If standard RSA ssh keys exist, these can be converted to public certs as well (and ssh keys can decrypt) | |
# | |
# To sign (and verify) the encrypted file, one of the private keys is required, see: | |
# http://www.openssl.org/docs/apps/smime.html#EXAMPLES for openssl smime examples | |
# or http://www.openssl.org/docs/apps/cms.html#EXAMPLES for cms utility (OpenSSL v. 1.0+) |
#!/usr/bin/env python | |
# python subnet.py 200.100.33.65/26 | |
# from: curl -O https://gist.githubusercontent.com/RichardBronosky/1aed6606b1283277e7ff9eaa18097e78/raw/subnet.py | |
import sys | |
# Get address string and CIDR string from command line | |
(addrString, cidrString) = sys.argv[1].split('/') | |
# Split address into octets and turn CIDR into int |
Replace this line with imperative summary | |
An awesome description of WHY you did this work, not HOW/WHAT it does. | |
The diff attached to commit should describe implementation (HOW) | |
well-enough. | |
# [TICKET-12] | |
#------------------------------------------------^---------------------^ | |
# 50^ 72^ |
This is a script that adds a fully functional Fork button to your own Gist.
If a Fork button is already present in the page, this bookmarklet will set focus to it instead of adding another one.
The change is temporary and the button will disappear as soon as you navigate away from that Gist (clicking the Fork button does this for you as well). Meaning you will have to run the script every new page load.
Copy the contents from bookmarklet.js, open Scracthpad (Ctrl+F4), paste it there. Back in browser, swwitch to tab with your Gist you want to fork. Back in Scratchpad, "Run" it. Save and/or bookmark the Scratchpad file for future use.
Want to fork your own gists? No fork button? No problem! Install this user script by clicking refork.user.js' "raw" link down below: ⇓
// Photoshop Script to Create iPhone Icons from iTunesArtwork | |
// Original: https://gist.github.com/appsbynight/3681050 | |
// Turn debugger on. 0 is off. | |
// $.level = 1; | |
try | |
{ | |
// Prompt user to select iTunesArtwork file. Clicking "Cancel" returns null. | |
var iTunesArtwork = File.openDialog("Select a sqaure PNG file that is at least 1024x1024.", "*.png", false); |