Created
October 11, 2018 11:34
-
-
Save adrianshort/5aa99c363ccab9a5e614ada0df99b958 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'uk_planning_scraper' | |
require 'csv' | |
apps = UKPlanningScraper::Authority.named('Aberdeen').scrape({ validated_days: 200, keywords: 'bt phone kiosk'}) | |
puts "#{apps.size} applications scraped." | |
CSV.open("aberdeen.csv", "w") do |csv| | |
csv << apps.first.keys # header row | |
apps.each { |app| csv << app.values } | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment