A "hledger check" argument may now be a quoted string containing
the check name followed by space-separated arguments, for
checks which make use of those. This means the check command
can replicate "check-dates --unique" and (in principle)
"check-fancyassertions ASSERTIONS..". Eg:
hledger check "dates --unique"
I think it'll be better for checks to take no arguments or options,
so this is probably just a transitional feature for compatibility.
This is intended to work in three modes:
- hledger check: just run the standard data checks, like all other
commands but with no output on success. Equivalent to
hledger stats >/dev/null but simpler and platform-independent.
- hledger check --strict: run the standard + strict data checks,
like other commands in strict mode.
- hledger check CHECK1 CHECK2 ...: run the named checks. This allows
running more or less checks than the default or strict mode, or
a single check of interest. The arguments are standard lowercase names
for the checks. For now this command supports two checks: "dates" and
"leafnames". These are equivalent to the check-dates and check-dupes
commands which are now hidden and considered deprecated, though
still supported for the moment.
This command needs more work and I'm rushing it a little, but I think
it's the right direction and I'd like to put it out there to get
feedback.
Command-line account aliases now also affect transactions read
from these formats (not just journal format).
lib: journalApplyAliases, transactionApplyAliases, postingApplyAliases
helpers have been added.