Skip to content

amitsuryavanshi/TwitterChallenge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Twitter Challenge

HashtagUrls::TwitterUrls is used to fetch all the unique http urls in the last 100 most recent tweets using the supplied hashtag.

How to use:

You can run the script by passing it a hash tag e.g.

$ ruby twitter_hashtag_urls.rb Hashtag

Sample Output:

  1. xyz.com

  2. pqr.com

  3. abc.com

Dependencies

This script is tested on 1.8.x Ruby version

Gems:

1.dancroak-twitter-search 0.5.8

2.json 1.6.6

3.rspec 2.9.0

Credits:

This script uses twitter-search library, created by Rafal Piekarski. Reposiory of which is at github.com/croaky/twitter-search.git

Usage

  1. put dancroak-twitter-search in your gemfile with source ‘gems.github.com

  2. require ‘hashtag_urls’

  3. client = HashtagUrls::TwitterUrls.new(‘hashtag’)

  4. client.urls

  5. if there are no tweets related to hashtag or no urls in tweets client.message will give you appropriate message

License

Copyright © 2012 Amit Suryavanshi

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages