Adrian Short 6 anni fa
committed by GitHub
commit
85caa071a0
1 ha cambiato i file con 10 aggiunte e 0 eliminazioni
  1. +10
    -0
      aberdeen.rb

+ 10
- 0
aberdeen.rb Vedi File

@@ -0,0 +1,10 @@
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

Caricamento…
Annulla
Salva