mirror of
https://github.com/simonmichael/hledger.git
synced 2024-11-12 19:08:34 +03:00
Allow comments for periodic transactions.
This commit is contained in:
parent
e1230d9929
commit
6c2385331c
@ -457,11 +457,13 @@ modifiertransactionp = do
|
|||||||
postings <- postingsp Nothing
|
postings <- postingsp Nothing
|
||||||
return $ ModifierTransaction valueexpr postings
|
return $ ModifierTransaction valueexpr postings
|
||||||
|
|
||||||
|
-- | Parse a periodic transaction
|
||||||
periodictransactionp :: MonadIO m => ErroringJournalParser m PeriodicTransaction
|
periodictransactionp :: MonadIO m => ErroringJournalParser m PeriodicTransaction
|
||||||
periodictransactionp = do
|
periodictransactionp = do
|
||||||
char '~' <?> "periodic transaction"
|
char '~' <?> "periodic transaction"
|
||||||
lift (skipMany spacenonewline)
|
lift (skipMany spacenonewline)
|
||||||
periodexpr <- T.pack <$> lift restofline
|
periodexpr <- T.pack . strip <$> descriptionp
|
||||||
|
_ <- try followingcommentp <|> (newline >> return "")
|
||||||
postings <- postingsp Nothing
|
postings <- postingsp Nothing
|
||||||
return $ PeriodicTransaction periodexpr postings
|
return $ PeriodicTransaction periodexpr postings
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user