Skip to content

Instantly share code, notes, and snippets.

View rcarver's full-sized avatar
:shipit:
Building Recentralized.

Ryan Carver rcarver

:shipit:
Building Recentralized.
View GitHub Profile
<script type="text/javascript">
// *** EXPERIMENTAL ***
//
// This is an experimental method to be notified when Typekit's fonts have loaded.
//
// It will almost certainly change! Please do not use this on a live site. Please
// do let us know what you think by forking this gist, contacting us at
// support@typekit.com or on Get Satisfaction - http://getsatisfaction.com/typekit
//
module Job
extend self
def low(klass, *args)
queue.enqueue(:low, klass, *args)
end
def high(klass, *args)
queue.enqueue(:high, klass, *args)
end
@rcarver
rcarver / gist:118854
Created May 27, 2009 19:41
Don't do this or Safari will randomly show a blank page and you will be sad
- render " ", :status => 304
+ render "", :status => 304
git push origin master
ssh ryancarver.com "cd ryancarver.com && git pull origin master"
$(document).ready(function() {
$('form').submit(function() {
var q = $("input#q").val();
$.getJSON("http://en.wikipedia.org/w/api.php?callback=?", {
search: q,
action: "opensearch",
format: "json" },
function(result) {
var suggestions = result[1];
# Set environment variables authorizing AWS for a specific account. Data is stored in:
# ~/.amazon_keys_[account]
# ~/.ec2_[account]/pk-*.pem
# ~/.ec2_[account]/cert-*.pem
# ~/.ec2_[account]/id_rsa-*
function aws {
export AWS_CURRENT=$1
# AWS
if [[ -f "$HOME/.amazon_keys_$1" ]]; then