Sha256: e39495499a29a32f8c01b6d14bc4310b98237997555071984e5605bd73fa3012
Contents?: true
Size: 572 Bytes
Versions: 8
Compression:
Stored size: 572 Bytes
Contents
require 'icalendar' require 'date' module Timetrap module Formatters class Ical include Icalendar def calendar @calendar ||= Calendar.new end def output calendar.to_ical end def initialize entries entries.each do |e| next unless e.end calendar.event do dtstart DateTime.parse(e.start.to_s) dtend DateTime.parse(e.end.to_s) summary e.note description e.note end end calendar.publish end end end end
Version data entries
8 entries across 8 versions & 2 rubygems