From a0c80041471ae2e9242143b7cb3690c4590e180a Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Fri, 9 Jan 2026 11:58:12 -1000 Subject: [PATCH] ;examples: debconf: make check-* --- examples/debconf/Makefile | 5 +++++ examples/debconf/README.md | 15 ++++++++++----- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/examples/debconf/Makefile b/examples/debconf/Makefile index 10d23adfe..56fa8174d 100644 --- a/examples/debconf/Makefile +++ b/examples/debconf/Makefile @@ -18,3 +18,8 @@ all: \ dc%: git clone --filter=blob:none --sparse http://salsa.debian.org/debconf-team/public/data/$@ git -C $@ sparse-checkout set --no-cone budget '!budget/invoices' + +# make check-ledger, check-hledger - check readability +check-%: + @for d in dc*; do printf "$$d: "; ledger -f $$d/budget/journal.ledger stats >/dev/null && echo ok; done + diff --git a/examples/debconf/README.md b/examples/debconf/README.md index 8822a36e9..02ab67752 100644 --- a/examples/debconf/README.md +++ b/examples/debconf/README.md @@ -1,9 +1,14 @@ -DebConf does their accounting with Ledger. +# DebConf ledgers +DebConf does their accounting with Ledger. Eg: -These repos are big; to clone just the accounting data for a few recent years, run `make` here. -Or to clone all years (starting 2017), `make all`. +Each year has its own repo, and the repos are big. +To clone just the accounting data for a few recent years: `make` +To clone all years, starting 2017: `make all` + +Some years (eg 24 and 25) can be read by hledger as-is; +others may need some conversion, eg of [amount expressions](https://hledger.org/ledger.html#amount-expressions). +To check hledger readability for the years you have downloaded: `make check-hledger` +To check ledger readability: `make check-ledger` -Some years (eg 24 and 25) can be read by hledger with no changes needed; -others may need some conversion, eg [amount expressions](https://hledger.org/ledger.html#amount-expressions).