Reformat long DOW regex over multiple lines

This commit is contained in:
Matt Snider 2019-01-21 20:36:07 +01:00
parent aa48ea1d3c
commit ef26faa356
1 changed files with 10 additions and 1 deletions

View File

@ -65,7 +65,16 @@ _PERIOD = r'(?P<period>hour|day|week|month|year)s?'
_EVERY = r'ev(ery)?'
_CYCLES = r'((?P<cycles>\d+)(st|nd|rd|th)?)'
_SIMPLE = r'(?P<simple>daily|weekly|monthly|yearly)'
_DOW = r'((?P<dayofweek>(mo(n(day)?)?|tu(e(s(day)?)?)?|we(d(s|(nes(day)?)?)?)?|th(u(rs(day)?)?)?|fr(i(day)?)?|sa(t(urday)?)?|su(n(day)?)?)))'
_DOW = (
r'((?P<dayofweek>('
r'mo(n(day)?)?'
r'|tu(e(s(day)?)?)?'
r'|we(d(s|(nes(day)?)?)?)?|th(u(rs(day)?)?)?'
r'|fr(i(day)?)?'
r'|sa(t(urday)?)?'
r'|su(n(day)?)?'
r')))'
)
# A single cycle recurrence is one of:
# - daily, weekly, monthly, yearly