Skip to content

Instantly share code, notes, and snippets.

@jookyboi
Created October 3, 2013 17:42
Show Gist options
  • Save jookyboi/6813881 to your computer and use it in GitHub Desktop.
Save jookyboi/6813881 to your computer and use it in GitHub Desktop.
agent = WWW::Mechanize.new
agent.get("http://www.awesomeblog.com/amazing-article")
scraper.text = MyScraper.new(:text => Pismo::Document.new(agent.url))
while agent.page.link_with("rel='next'").click do
pismo_doc = Pismo::Document.new(agent.url)
scraper.text << pismo_doc.lede
end
scraper.save!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment