Thanks for the input André.
I didn't understand how installing the add-on failed. Any more details ?
Also, although I've been using and talking about these matched assets/liabilities to and from zero transactions at year file boundaries for years, until now I haven't heard of anybody else doing the same thing. Is the technique useful enough to be a built-in command, or is everybody else doing something different ? (for those of you just tuning in: see the hledger-equity doc below for the use case).
Re two commands rather than one, I thought that running the "open" command against the old journal might be a bit non-obvious:
hledger close -f 2016.journal assets liabilities # "makes sense"
hledger open -f 2016.journal assets liabilities # "weird, aren't I opening a 2017 journal ?"
Also, I thought that you would pretty much always be running "close" and then "open", so why not make it a more convenient single command.
If two commands, "open" and "close" are nice easy words, but too overloaded with other meanings, probably (?):
1. "Closing the books" has a definite meaning in accounting (see below)
2. opening and closing is a familiar operation on real-world accounts (creating and destroying)
3. Beancount's journal format has open and close keywords for modelling 2, which we might want to support in future
Other ideas besides your suggestion: zero/unzero ? tozero/fromzero ? tofromzero ? endingbalanceclopen ?
In Ledger and hledger this command uses a hard-coded "equity:..." account name as the balancing account. Is that always what you want ? Is "equity" the right word after all ? If someone could explain why it's the best name for this command, I'll happily leave it alone.
Closing entries are journal entries used to empty temporary accounts at the end of a reporting period and transfer their balances into permanent accounts. The use of closing entries resets the temporary accounts to begin accumulating new transactions in the next period. Otherwise, the balances in these accounts would be incorrectly included in the totals for the following reporting period.
The basic sequence of closing entries is:
• Debit all revenue accounts and credit the income summary account, thereby clearing out the balances in the revenue accounts.
• Credit all expense accounts and debit the income summary account, thereby clearing out the balances in all expense accounts.
• Close the income summary account to the retained earnings account. If there was a profit in the period, then this entry is a debit to the income summary account and a credit to the retained earnings account. If there was a loss in the period, then this entry is a credit to the income summary account and a debit to the retained earnings account.
The net result of these activities is to move the net profit or loss for the period into the retained earnings account, which appears in the stockholders' equity section of the balance sheet.
Since the income summary account is only a transitional account, it is also acceptable to close directly to the retained earnings account and bypass the income summary account entirely.
Soo.. as usual, a bit different from our language. How do these people manage without a hierarchical account names ? :) I guess "retained earnings" is a kind of equity ?
Cc'ing the Ledger list for more advice.