Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

26 lines (20 sloc) 0.421 kb
require 'vpim/icalendar'
require 'open-uri'
class Convert
def initialize(io)
@io = io
end
def each
@io.each do |line|
line.gsub!("\r", "\\n")
yield line
end
end
end
io = open("http://upcoming.org/calendar/metro/45")
cvt = Convert.new(io)
cal = Vpim::Icalendar.decode(cvt).first
cal.components do |c|
puts "-------------------------------------------------"
puts c.description
end
Jump to Line
Something went wrong with that request. Please try again.