node-ledger
node-ledger copied to clipboard
Stats returns 'Failed to parse Ledger stats' for files with no postings
I am (ab)using stats to have ledger validate some files that don't contain any posting. They could be legitimate files. Imagine a file containing only prices or a file containing only a budget. Something like
P 2016/12/31 $ £0.81
or something like
~ Monthly Expenses:House:Rent £1000 Assets
If I invoke ledger stats from the command line I get an empty output, which triggers the error.
Is that necessary?