Skip to content

Instantly share code, notes, and snippets.

@bartolsthoorn
Created March 14, 2013 12:43
Show Gist options
  • Save bartolsthoorn/5161026 to your computer and use it in GitHub Desktop.
Save bartolsthoorn/5161026 to your computer and use it in GitHub Desktop.
Wombat is pretty cool
results = Wombat.crawl do
base_url "#{uri.scheme}://#{uri.host}"
path uri.path
title xpath: '//title'
meta do
description xpath: '//meta[@name="description"]/@content'
keywords xpath: '//meta[@name="keywords"]/@content'
end
mailto "xpath=//a[starts-with(@href, 'mailto')]", :list
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment