Skip to content

Instantly share code, notes, and snippets.

View pikesley's full-sized avatar
💭
I fly cargo planes full of rubber dogshit out of Hong Kong

pikesley pikesley

💭
I fly cargo planes full of rubber dogshit out of Hong Kong
View GitHub Profile
@pikesley
pikesley / WAT.rb
Created June 14, 2013 08:24 — forked from pezholio/WAT.rb
require 'nokogiri'
require 'open-uri'
uri = "http://data.gov.uk/dataset/water-framework-directive-lake-waterbodies-wfs"
rdf = nil
doc = Nokogiri::HTML(open(uri))
doc.search('link[rel=alternate]').each do |e|
@pikesley
pikesley / 01.md
Created October 28, 2012 18:25 — forked from mrchrisadams/01.md

In my spare time, I've recently been working with a few codebases that either are written in, or use enough code written in, nodejs, that make me keen to have some kind of testing framework in place to help put the same kinds of safety nets in place that I'm used to working with on Chef, Sinatra or Rails projects.

After losing a couple of weekends to trying to find an approach to BDD style development with node, and getting my head around asynchronous coding concepts, I think I've settled on an approach that feels enough like rspec to feel comfortable enough to use for future serverside js development.

It's way too much for a single post, so I'll be sharing the first of a three part series of posts, to help other Ruby developers used to synchronous development with rspec, adjust to asynchronous development, with the closest thing I can find to rspec right now, mocha.

I'll cover how Mocha syntax compares to rspec, then I'll cover implementing the code to pass these mocha specs, then I'll add a post to help

@pikesley
pikesley / 01.md
Created October 28, 2012 18:25 — forked from mrchrisadams/01.md

In my spare time, I've recently been working with a few codebases that either are written in, or use enough code written nodejs, that make me keen to have some kind of testing framework in place to help put the same kinds of safety nets in place that I'm used to working with on Chef, Sinatra or Rails projects.

After losing a couple of weekends to trying to find an approach to BDD style development with node, and getting my head around asynchronous coding concepts, I think I've settled on an approach that feels enough like rspec to feel comfortable enough to use for future serverside js development.

It's way too much for a single post, to I'll be sharing the first of a three part series of posts, to help other Ruby developers used to synchronous development with rspec, adjust to asynchronous development, with the closest thing I can find to rspec right now, mocha.

I'll cover how Mocha syntax compares to rspec, then I'll cover implementing the code to pass these mocha specs, then I'll add a post to help keep

@pikesley
pikesley / blogpost.md
Created August 29, 2012 10:34 — forked from mrchrisadams/blogpost.md
Tying together sendgrid and kissmetrics

At AMEE, we've been using Sendgrid (to take care of delivering email) and KissMetrics (to help us understand in detail how our apps are used) for a while now (we'd never be able to deliver the same level of service internally as they can, and they get better for free), but as is often the case when working with disparate third party services, they don't always work together how you want.

One of the reasons we use these two services however, is that they provide a rich enough API to combine them to plug gaps like we mentioned above.

For example, we use Sendgrid for transactional email, and it does a sterling job when it comes to actually making sure email ends up in the right inbox. But if we wanted to see what a user did with an email it had arrived, and log that for analysis later, we could't find a simple way to do this.

Likewise with KissMetrics - it's straightforward enough to create a libary of events in the browser to log, that you can then combine in groups to build reports on how well a certain