Skip to content

Instantly share code, notes, and snippets.

@muffinista
Forked from JonHilton/gist:7253954
Last active December 27, 2015 02:39
Show Gist options
  • Save muffinista/7254128 to your computer and use it in GitHub Desktop.
Save muffinista/7254128 to your computer and use it in GitHub Desktop.
loop do
search "medbotqna SGUL finals" do |tweet|
txt = tweet[:text]
if txt =~ /001/
reply "#{tweet_user(tweet)} Here is your question - SGUL finals", tweet
reply "#{tweet_user(tweet)} Mrs Jones is a 68 year old life long smoker who has an operation next week. To continue please reply with SGUL finals 002", tweet
elsif txt =~ /002/
# stuff to handle 002 here
elsif txt =~ /003/
# stuff to handle 003 here
end
end
update_config
sleep 60
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment