Skip to content

Instantly share code, notes, and snippets.

Avatar
:octocat:

Dave Lester davelester

:octocat:
View GitHub Profile
@robinsloan
robinsloan / langoliers.rb
Last active Apr 29, 2022
The Langoliers, a tweet deletion script
View langoliers.rb
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"
@justgrimes
justgrimes / gist:2348459
Created Apr 10, 2012
publiclibraries.com scraper
View gist:2348459
# publiclibraries.com scraper
import BeautifulSoup
import urllib2
l = [("http://www.publiclibraries.com/alabama.htm","AL"),
("http://www.publiclibraries.com/alaska.htm","AK"),
("http://www.publiclibraries.com/arizona.htm","AZ"),
("http://www.publiclibraries.com/arkansas.htm","AR"),
("http://www.publiclibraries.com/california.htm","CA"),
@jblomo
jblomo / WordCount.java
Created Mar 23, 2012
Hadoop MR JSON example
View WordCount.java
import java.io.IOException;
import java.util.*;
import org.codehaus.jackson.map.ObjectMapper;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.conf.*;
import org.apache.hadoop.io.*;
import org.apache.hadoop.mapred.*;
import org.apache.hadoop.util.*;