Skip to content

Instantly share code, notes, and snippets.

Matt Biddulph mattb

Block or report user

Report or block mattb

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:2214
require 'rubygems'
require 'fireeagle'
require 'twitter'
# get yourself an access token by hand on the irb commandline with the oauth gem
fe = FireEagle::Client.new(:consumer_key => "<yourkey>", :consumer_secret => "<yoursecret>", :access_token => "<youraccesstoken>", :access_token_secret => "<youraccesstokensecret>")
t=Twitter::Base.new "<yournick>","<yourpassword>"
lat = nil
lng = nil
while true
View gist:2544
def parse(x)
$joined = 0
$counter = 0
# INITIALIZE VARIABLES
upmynick = $irc_nick
mynick = upmynick.downcase
nick = ""
chan = ""
View gist:22223
#!/usr/bin/env ruby
require '/Users/mattb/Work/Dopplr/code/dopplr/config/environment'
require 'fire_hydrant'
config = YAML.load(File.read("fire_hydrant.yml"))
hydrant = FireHydrant.new(config, false)
hydrant.jack!(OAuthPubSubJack)
hydrant.on_startup do
defer :subscribed do
View gist:25502
$.getJSON('http://api.flickr.com/services/rest/?method=flickr.places.getInfo&api_key=get_your_own&woe_id=44418&format=json&jsoncallback=?', function(data) {
if(data.place.has_shapedata == 1) {
var bounds = new GLatLngBounds();
$.each(data.place.shapedata.polylines.polyline, function(index,polyline) {
thepoints = [];
$.each(polyline._content.split(/ /), function(pindex, point) {
lat = parseFloat(point.split(/,/)[0]);
lng = parseFloat(point.split(/,/)[1]);
thepoints[pindex] = new GLatLng(lat, lng);
});
View gist:118562
require 'rubygems'
require 'xml' # libxml2 ruby bindings
# TABLE SCHEMA:
#create table flickr_shapes (id int not null auto_increment primary key, kind varchar(255), label varchar(255), woe_id int, min_lat decimal(20,17), min_lng decimal(20,17), max_lat decimal(20,17), max_lng decimal(20,17));
# USE:
#select * from flickr_shapes where 51.52830123901367 between min_lat and max_lat AND -0.0916564017534256 between min_lng and max_lng;
class MyCallbacks
include XML::SaxParser::Callbacks
View gist:123232
require 'open-uri' ; require 'rss/2.0' ; require 'cgi'
delicious_user='mattb'
instapaper_user='me@example.com'
instapaper_password='whatever'
RSS::Parser.parse(open('http://feeds.delicious.com/v2/rss/network/#{delicious_user}?count=15').read).items.each { |item| open("https://www.instapaper.com/api/add?username=#{instapaper_user}&password=#{instapaper_password}&url=#{CGI.escape(item.link)}&auto-title=1").read }
View gist:148362
require 'rubygems'
require 'eventmachine'
require 'yajl'
require 'em-http'
require 'uri'
EventMachine.run {
body = ''
on_body = lambda { |chunk|
chunk.split(/\n/).each { |json|
View gist:372204
Senior Frontend Developer
Description
The Services business unit plays a leading role in shaping Nokia's
growth and transformation into an internet company by generating new
revenue streams based on software and services. We are fundamentally
changing the perception of Nokia in the market. The Services unit
portfolio includes Ovi-branded services such as maps, music, games,
social networking, sharing, and email which create opportunities for
View gist:372208
Senior Web Designer
Nokia's Services Unit plays a leading role in shaping Nokia's growth
and transformation into an Internet company by generating new revenue
streams based on software and services. We are fundamentally changing
the perception of Nokia in the market. The Services Unit's portfolio
includes Ovi-branded services such as maps, music, games, social
networking, sharing, and email which create opportunities for people to
connect to each other and the things that matter to them. The developed
services and software can be used on PCs, online or on mobile devices,
View gist:487613

Reeder, Simplenote, Twitterific, Amazon Kindle, Instapaper Pro, Goodreader, Weather Pro HD, Dropbox, Plants vs Zombies, IMDb, Guardian Eyewitness, Flipboard, Articles, FlickStackr, FlightTrack, PONS German dictionary, Marvel comics, Canabalt, Osmos HD

You can’t perform that action at this time.