Exceptions are for dealing with the pamount field, which is really just
dealing with an unnormalised list of amounts.
This creates an API for dealing with MixedAmount, so we never have to
access the internals outside of Hledger.Data.Amount.
Also remove a comment, since it looks like #1207 has been resolved.
This seems to be fallout from #1340's
2020-09-16 d0d39e615 lib,cli,ui,web: Introduce ReportSpec, which holds ReportOpts, the day of the report, and the parsed Query.
querystring_.
This helps deal with tricky quoting issues, as we no longer have to make
sure everything is quoted properly before merging it into a string.
Previously showMixedAmountElided would show two amounts and then the
elision string if necessary. Now it will display as many Amounts as it
can subject to the condition that the amounts plus the elision string
fit within 22 characters.
This is an API change, but it seems better than having additional
colour-supporting variants and trying to avoid duplicated code.
I stopped short of changing showAmount, so cshowAmount still exists.
Periodic transactions were always on, which meant that periodic
transactions occurring today were always shown, in future or present
mode.
Now, both periodic transactions and display of future transactions are
controlled by --forecast, and toggleable by the F key ("forecast
mode"). The --future flag has been dropped (it still works as a hidden
alias for --forecast, but is deprecated).
It seemed to also make sense to leave auto postings off by default,
like hledger.
You may have transactions dated later than today, perhaps piped from
print --forecast or recorded in the journal, which you don't want to
see except when forecasting.
By default, we now hide future transactions, showing "today's balance".
This can be toggled with the F key, which is easier than setting a
date query. --present and --future flags have been added to set the
initial mode.
(Experimental. Interactions with date queries have not been explored.)
Builtin commands are now gathered more tightly in a single module,
Hledger.Cli.Commands, reducing duplication and facilitating change.
The tests command was difficult and has been dropped for now.
The obsolete convert/info/man commands have been dropped.
cli: refactor: a proper commands list, better Main/Commands separation
The legacy "convert" command has been dropped.
The activity command's module is now named consistently.