Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ondenman committed Aug 1, 2016
0 parents commit b825c10
Show file tree
Hide file tree
Showing 3 changed files with 91 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# frozen_string_literal: true

source "https://rubygems.org"

gem "twitter"
gem 'twitter_list', git: "https://github.com/everypolitician/twitter_list"
gem 'scraperwiki', git: 'https://github.com/openaustralia/scraperwiki-ruby', branch: 'morph_defaults'
71 changes: 71 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
GIT
remote: https://github.com/everypolitician/twitter_list
revision: 25087ee3d4b97a0bfeac37d9c915d018d1ce453b
specs:
twitter_list (0.0.1)
twitter

GIT
remote: https://github.com/openaustralia/scraperwiki-ruby
revision: fc50176812505e463077d5c673d504a6a234aa78
branch: morph_defaults
specs:
scraperwiki (3.0.1)
httpclient
sqlite_magic

GEM
remote: https://rubygems.org/
specs:
addressable (2.4.0)
buftok (0.2.0)
domain_name (0.5.20160615)
unf (>= 0.0.5, < 1.0.0)
equalizer (0.0.10)
faraday (0.9.2)
multipart-post (>= 1.2, < 3)
http (1.0.4)
addressable (~> 2.3)
http-cookie (~> 1.0)
http-form_data (~> 1.0.1)
http_parser.rb (~> 0.6.0)
http-cookie (1.0.2)
domain_name (~> 0.5)
http-form_data (1.0.1)
http_parser.rb (0.6.0)
httpclient (2.8.0)
json (1.8.3)
memoizable (0.4.2)
thread_safe (~> 0.3, >= 0.3.1)
multipart-post (2.0.0)
naught (1.1.0)
simple_oauth (0.3.1)
sqlite3 (1.3.11)
sqlite_magic (0.0.6)
sqlite3
thread_safe (0.3.5)
twitter (5.16.0)
addressable (~> 2.3)
buftok (~> 0.2.0)
equalizer (= 0.0.10)
faraday (~> 0.9.0)
http (~> 1.0)
http_parser.rb (~> 0.6.0)
json (~> 1.8)
memoizable (~> 0.4.0)
naught (~> 1.0)
simple_oauth (~> 0.3.0)
unf (0.1.4)
unf_ext
unf_ext (0.0.7.2)

PLATFORMS
ruby

DEPENDENCIES
scraperwiki!
twitter
twitter_list!

BUNDLED WITH
1.12.5
13 changes: 13 additions & 0 deletions scraper.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/env ruby
# encoding: utf-8

require 'rubygems'
require 'bundler/setup'

require 'scraperwiki'
require 'twitter_list'

abort "Need to set ENV['MORPH_TWITTER_TOKENS']" unless ENV.key? 'MORPH_TWITTER_TOKENS'
twitter_list = TwitterList::Scraper.new(twitter_tokens: ENV['MORPH_TWITTER_TOKENS'])

ScraperWiki.save_sqlite([:id], twitter_list.people('Europarl_EN', 'all-meps-on-twitter'))

0 comments on commit b825c10

Please sign in to comment.