I've been wrestling with the decision to move from ledger-cli to hledger for 18+ months. Yesterday, I finally committed to making the move, and with a lot of trial and error, I managed to transition successfully.
One thing that's really bothering me, though, is automatic transactions. I have a rule to calculate tithes on income. My preference is to have the calculation performed on anything in the Income account unless I specifically exclude it. With hledger, the regex I used with ledger-cli doesn't seem to work, and instead, I am forced to specify all of the accounts I want to include instead.
How can I achieve the ledger-cli behavior in hledger?
ledger-cli rule= /^Income:(?!Exc1|Exc2|Exc3|Exc4|Exc5)/ (Liabilities:Tithe) 0.10 hledger rule= ^Income:^Income:Inc1|^Income:Inc2Gift|^Income:Inc4|^Income:Inc5 (Liabilities:Tithe) *0.10
Thanks
JL