From a99607825349c0f75383a41de757a78ef02b9dfd Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Mon, 31 Oct 2022 18:31:22 -1000 Subject: [PATCH] doc: cli: expand --debug help --- hledger/hledger.m4.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/hledger/hledger.m4.md b/hledger/hledger.m4.md index 830243a2b..07b37a7cd 100644 --- a/hledger/hledger.m4.md +++ b/hledger/hledger.m4.md @@ -1748,9 +1748,11 @@ $ hledger print -o foo.txt $ hledger print -o - # write to stdout (the default) ``` -hledger can optionally produce debug output (if enabled with `--debug=N`); -this goes to stderr, and is not affected by `-o/--output-file`. -If you need to capture it, use shell redirects, eg: `hledger bal --debug=3 >file 2>&1`. +hledger can produce debug output (if enabled with `--debug[=N]`). +N ranges from 1 (least output, the default) to 9 (maximum output). +Debug output goes to stderr, and is not affected by `-o/--output-file`. +It will appear interleaved with normal output, which can help in understanding when code is evaluated. +To capture it in a log file instead, use shell redirects, eg: `hledger bal --debug=3 2>hledger.log`. ## Output styling