Skip to content

Instantly share code, notes, and snippets.

@ckolderup
Created July 8, 2014 19:20
Show Gist options
  • Save ckolderup/998c58bba94a8bb71302 to your computer and use it in GitHub Desktop.
Save ckolderup/998c58bba94a8bb71302 to your computer and use it in GitHub Desktop.
drilsay - make your OS X install read wint to you whenever he tweets
require 'tweetstream'
TweetStream.configure do |config|
config.consumer_key = ENV['TWITTER_OAUTH_KEY']
config.consumer_secret = ENV['TWITTER_OAUTH_SECRET']
config.auth_method = :oauth
end
TweetStream::Client.new.follow(16298441) do |status|
puts status.text
`echo "#{status.text}" | say -v Ralph`
end
source 'https://rubygems.org'
gem 'tweetstream'
gem 'foreman'
@ckolderup
Copy link
Author

put the environment variables in .env and rbenv exec bundle exec foreman run ruby drilsay.rb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment