Last active
August 14, 2019 17:44
-
-
Save rbnpercy/d3af52979e38ef4f6d195cd7282141d2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'feedjira' | |
def hn_articles | |
url = "https://news.ycombinator.com/rss" | |
feed = Feedjira::Feed.fetch_and_parse url | |
arts = feed.entries.each do |item| | |
puts "Item: #{item.title}" | |
puts "&& Link: #{item.url}" | |
end | |
return arts.inspect | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment