X-Git-Url: https://git.ucc.asn.au/?p=frenchie%2Ficalparse.git;a=blobdiff_plain;f=parserrules.py;h=98405f3d87a5efe00c2675a6b4b984e94ce58836;hp=4f71e622885e343b61db1f6b419ef54db9a65e82;hb=d0370197c1715b2d2eb47ee190dfd92b62dada39;hpb=e21f977abbd6f72899bafaf97670f443ea2e1217 diff --git a/parserrules.py b/parserrules.py index 4f71e62..98405f3 100644 --- a/parserrules.py +++ b/parserrules.py @@ -22,13 +22,16 @@ # This file describes a series of rules which will be called on an ics file as # rule(key, value) -# Your functions are expected to return a (key, value) tuple or they will be treated as -# if they don't exist (ie, the line will go through unhindered). Returning an value which -# is boolean False will remove the offending line from the final ICS (unless it's a None). +# Your functions are expected to return a (key, value) tuple or they will be +# treated as if they don't exist (ie, the line will go through unhindered). +# Returning any boolean false value other than a None will return the line from +# the final iCalendar file -# The doc string will be presented to the user when run as verbose, so please be polite +# The doc string will be presented to the user when run as verbose, so +# please be polite def markEventsPublic(key, value): '''Marking private events public''' - # Required as google are strict about the CLASS:PRIVATE/CLASS:CONFIDENTIAL lines + # Required as google are strict about the CLASS:PRIVATE/CLASS:CONFIDENTIAL + # lines and Facebook like to set them if key == 'CLASS': return (key, 'PUBLIC')