Aupajo / almanack

Aggregate iCal and Google Calendar events. Pluggable or standalone app. UI optional and 100% customisable.
MIT License
54 stars 25 forks source link

feature request. parse #29

Open steveb85 opened 5 years ago

steveb85 commented 5 years ago

Would it be hard to modify, so that all event details are parsed, leaving only the title "Busy" and the time, no location, details, invites etc etc. I know that Google and Exchange servers support this, but iCloud doesn't have this feature anymore. I can do it in the styling, but that doesn't actually change the ics file which is sync'd by external calendar programs.

Aupajo commented 5 years ago

@steveb85 No, I don't think it would be too hard to do.

You could monkey-patch the Event class:

# config.ru
require 'almanack/server'

class Almanack::Event < OpenStruct
  def initialize(**attrs)
    attrs.merge!(title: "Busy", location: nil, description: nil)
    super
  end
end

Almanack.configure do |c|
# ...

This is a brittle solution, as I might change how event construction works in future releases but would solve your immediate issue.

steveb85 commented 5 years ago

This is perfect!! thanks @Aupajo got it up and running already! appreciate it!