;examples: update some budget examples

This commit is contained in:
Simon Michael 2020-11-20 16:53:08 -08:00
parent 654ab4243a
commit 126bb44eec

View File

@ -16,35 +16,15 @@
; Some examples of the balance --budget report, ; Some examples of the balance --budget report,
; which compares the actual (so far) and forecasted amounts. ; which compares the actual (so far) and forecasted amounts.
; There are some open bugs; here is output from several hledger versions: ; There are still some UX issues.
comment comment
; the totals row has always been wrong (a bug) ; Since 1.19.99, columns shrink to fit and can vary in width.
$ hledger-1.15 -f examples/budgeting/budget1.journal bal --budget -M ; Note Jan is showing no budget goal here (since 1.16), because "~ monthly"
Budget performance in 2020q1: ; generates transactions on the first of each month, but the report's
; start date here is 1/15 (the earliest transaction date) so the
|| Jan Feb Mar ; january budget goal transaction is excluded.
===============++===================================================================== $ hledger -f forecast-budget-1.journal bal --budget -M
<unbudgeted> || $-400 0 $-600
expenses || $400 [ 80% of $500] 0 [ 0% of $500] $600 [ 120% of $500]
expenses:food || $400 [ 80% of $500] 0 [ 0% of $500] $600 [ 120% of $500]
---------------++---------------------------------------------------------------------
|| 0 [ 0% of $500] 0 [ 0% of $500] 0 [ 0% of $500]
; since 1.16, Jan is showing no info (a bug)
; since 1.19, the boring parent "expenses" is elided by default
$ hledger-1.19.1 -f examples/budgeting/budget1.journal bal --budget -M
Budget performance in 2020Q1:
|| Jan Feb Mar
===============++=====================================================================
<unbudgeted> || $-400 0 $-600
expenses:food || $400 0 [ 0% of $500] $600 [ 120% of $500]
---------------++---------------------------------------------------------------------
|| 0 0 [ 0% of $500] 0 [ 0% of $500]
; since 1.19.99, columns shrink to fit and can vary in width
$ hledger -f examples/budgeting/budget1.journal bal --budget -M
Budget performance in 2020Q1: Budget performance in 2020Q1:
|| Jan Feb Mar || Jan Feb Mar
@ -53,3 +33,26 @@ Budget performance in 2020Q1:
expenses:food || $400 0 [0% of $500] $600 [120% of $500] expenses:food || $400 0 [0% of $500] $600 [120% of $500]
---------------++--------------------------------------------- ---------------++---------------------------------------------
|| 0 0 [0% of $500] 0 [ 0% of $500] || 0 0 [0% of $500] 0 [ 0% of $500]
; You have to specify explicit report dates to work around, eg:
$ hledger -f forecast-budget-1.journal bal --budget -M date:q1
Budget performance in 2020Q1:
|| Jan Feb Mar
===============++===========================================================
<unbudgeted> || $-400 0 $-600
expenses:food || $400 [80% of $500] 0 [0% of $500] $600 [120% of $500]
---------------++-----------------------------------------------------------
|| 0 [ 0% of $500] 0 [0% of $500] 0 [ 0% of $500]
; adding -E expands the <unbudgeted> account name for some reason
$ hledger -f forecast-budget-1.journal bal --budget -ME
Budget performance in 2020Q1:
|| Jan Feb Mar
==============================++=============================================
<unbudgeted>:assets:checking || $-400 0 $-600
expenses:food || $400 0 [0% of $500] $600 [120% of $500]
------------------------------++---------------------------------------------
|| 0 0 [0% of $500] 0 [ 0% of $500]