Create a gist now

Instantly share code, notes, and snippets.

# To parse a tweet from twitter to get teh '@' , '#' and the text seperated
parsed_text = tweet.text.gsub(/ ?(@\w+)| ?(#\w+)/) { |a| ((a.include?('#')) ? tags : replies) << a.strip.gsub(/#|@/,''); '' }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment