Making Rails time zone aware attributes and Chronic play well together
I came up with this monkeypatch to Time.zone.parse, so that it uses the Chronic time parsing library instead of Time.parse:
class ActiveSupport::TimeZone
# requires technoweenie’s fork of the Chronic time parsing library
# http://github.com/technoweenie/chronic/tree/master
def parse(str)
Chronic.time_class = self
Chronic.parse(str, :now => now)
end
end
…with this in place, I can assign natural language date/time strings [...]