mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-05-19 11:30:22 -07:00
X.P.OrgMode: Include 00:xx and xx:00 in the date range
This commit is contained in:
parent
8b4560dc1e
commit
b627306772
@ -533,12 +533,12 @@ pPriority = option NoPriority $
|
|||||||
pTimeOfDay :: Parser (Maybe TimeOfDay)
|
pTimeOfDay :: Parser (Maybe TimeOfDay)
|
||||||
pTimeOfDay = option Nothing $
|
pTimeOfDay = option Nothing $
|
||||||
skipSpaces *> choice
|
skipSpaces *> choice
|
||||||
[ Just <$> (TimeOfDay <$> pHour <* string ":" <*> pMinute) -- HH:MM
|
[ Just <$> (TimeOfDay <$> pHour <* ":" <*> pMinute) -- HH:MM
|
||||||
, Just <$> (TimeOfDay <$> pHour <*> pure 0 ) -- HH
|
, Just <$> (TimeOfDay <$> pHour <*> pure 0 ) -- HH
|
||||||
]
|
]
|
||||||
where
|
where
|
||||||
pMinute :: Parser Int = pNumBetween 1 60
|
pMinute :: Parser Int = pNumBetween 0 59
|
||||||
pHour :: Parser Int = pNumBetween 1 24
|
pHour :: Parser Int = pNumBetween 0 23
|
||||||
|
|
||||||
-- | Parse a 'Date'.
|
-- | Parse a 'Date'.
|
||||||
pDate :: Parser Date
|
pDate :: Parser Date
|
||||||
|
Loading…
x
Reference in New Issue
Block a user