Skip to content

Instantly share code, notes, and snippets.

View robinsloan's full-sized avatar

Robin Sloan robinsloan

View GitHub Profile
@robinsloan
robinsloan / argh.rb
Created July 1, 2011 01:13
Arghhhh
# 4<w<8, 1<y<10, x and z are 6-sided dice.
HOW_MANY = 100000
def range_rand(min,max)
min + rand(max-min)
end
def test_it
w = range_rand(4,8)
@robinsloan
robinsloan / wi.rb
Created August 4, 2011 05:49
Netflix Watch Instantly script for @queuenoodle
require 'rubygems'
require 'net/http'
require 'json'
require 'date'
module WatchInstantly
NUM_DAYS = 13
# main method
@robinsloan
robinsloan / smallscore.txt
Created August 10, 2011 03:16
A Small Score, Delmore Schwartz
Meek, sang the crickets, wheat, meet, creek,
And the birds sang tutti, all of them:
"Bubble, little,
Whistle, pretty,
Trickle, whittle,
Lipping and dripping
Sipping the well
Where the fawn dipped
Before dawn descended
And darkness surrendered
@robinsloan
robinsloan / summerknowledge.txt
Last active September 26, 2015 17:57
Summer Knowledge, Delmore Schwartz
Summer knowledge is not the winter's truth, the truth of fall,
the autumn's fruition, vision and recognition:
It is not May knowledge, little and leafing and growing green,
blooming out and blossoming white,
It is not the knowing and the knowledge of the gold fall and
the ripened darkening vineyard,
Nor the black tormented, drenched and rainy knowledge of birth,
April, and travail,
The knowledge of the womb's convulsions, and the coiled cord's
ravelled artery, severed and cut open,
@robinsloan
robinsloan / gist:1938148
Created February 29, 2012 05:25
Robert Penn Warren on the West
For West is where we all plan to go some day.
It is where you go when the land gives out and the old-field pines encroach.
It is where you go when you get the letter saying: Flee, all is discovered.
It is where you go when you look down at the blade in your hand and the blood on it.
It is where you go when you are told that you are a bubble on the tide of empire.
It is where you go when you hear that thar's gold in them-thar hills.
It is where you go to grow up with the country.
It is where you go to spend your old age.
Or it is just where you go.
@robinsloan
robinsloan / gist:1974889
Created March 4, 2012 21:33
BBC scones
2 c flour
2 tsp baking powder
0.5 tsp salt
2 tbsp sugar
0.25 c butter (rubbed into dry ingredients above)
~1 c milk (add slowly)
400 F, ~10-15 minutes.
@robinsloan
robinsloan / gist:3161873
Last active October 7, 2015 11:58
AMI Ruby setup recipe
# all yums prefixed w/ sudo
yum update
yum erase ruby ruby-libs
yum groupinstall "Development Tools"
# yum install git-core curl (already included in above)
@robinsloan
robinsloan / verbs.css
Created August 20, 2012 20:12
Responsive verbs
.clickTouchCap:before {
content: 'Click';
}
.clickTouch:before {
content: 'click';
}
@media only screen and (max-width: 767px) {
@robinsloan
robinsloan / poet.txt
Created August 22, 2012 00:07
Constructing a poet
# http://www.theparisreview.org/interviews/482/the-art-of-poetry-no-83-billy-collins
INTERVIEWER
If you had to construct a poet out of whole cloth, so to speak, what attributes would you give
him or her?
COLLINS
A Frankenstein monster! First, a sense of attentiveness. Then wanting to hang around the
@robinsloan
robinsloan / langoliers.rb
Last active April 7, 2024 13:22
The Langoliers, a tweet deletion script
require "rubygems"
require "twitter"
require "json"
# things you must configure
TWITTER_USER = "your_username"
MAX_AGE_IN_DAYS = 1 # anything older than this is deleted
# get these from dev.twitter.com
CONSUMER_KEY = "your_consumer_key"