Code Repositories xandikos / 41136c1
Clearer commit messages for a few more VTODO elements. Jelmer Vernooń≥ 1 year, 6 months ago
1 changed file(s) with 19 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
117117 old_component.name.upper() == "VTODO" and
118118 field.upper() == "STATUS"
119119 ):
120 yield "%s marked as %s" % (description, new_value)
120 human_readable = {
121 "NEEDS-ACTION": "needing action",
122 "COMPLETED": "complete"
123 }
124 yield "%s marked as %s" % (
125 description,
126 human_readable.get(new_value.upper(), new_value))
121127 elif field.upper() == 'DESCRIPTION':
122128 yield "changed description of %s" % description
123129 elif field.upper() == 'SUMMARY':
133139 yield "changed due date for %s from %s to %s" % (
134140 description, old_value.dt if old_value else 'none',
135141 new_value.dt if new_value else 'none')
142 elif field.upper() == 'DTSTART':
143 yield "changed start date/time of %s from %s to %s" % (
144 description, old_value.dt if old_value else 'none',
145 new_value.dt if new_value else 'none')
146 elif field.upper() == 'DTEND':
147 yield "changed end date/time of %s from %s to %s" % (
148 description, old_value.dt if old_value else 'none',
149 new_value.dt if new_value else 'none')
150 elif field.upper() == 'CLASS':
151 yield "changed class of %s from %s to %s" % (
152 description, old_value.lower() if old_value else 'none',
153 new_value.lower() if new_value else 'none')
136154 else:
137155 yield "modified field %s in %s" % (field, description)
138156 logging.debug("Changed %s/%s or %s/%s from %s to %s.",