From 4b4c12a9ea35a18b8969aa7e8994ebd306a5d1be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=B6rnquist?= Date: Thu, 30 Dec 2021 16:58:50 +0100 Subject: Move config print to own flag. All the configuration variables hid the actually useful information. --- module/calp/main.scm | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'module/calp/main.scm') diff --git a/module/calp/main.scm b/module/calp/main.scm index a27e4c38..770be556 100644 --- a/module/calp/main.scm +++ b/module/calp/main.scm @@ -63,7 +63,12 @@ (update-zoneinfo) (help (single-char #\h) - (description "Print this help")))) + (description "Print this help")) + + (printconf (description "Print known configuration variables." + (br) (b "NOTE") ": " + "Only those configuration variables which are loaded " + "will be shown, more might be available")))) (define module-help '(*TOP* (br) @@ -185,6 +190,9 @@ (display (sxml->ansi-text module-help) (current-output-port)) (print-arg-help options) + (throw 'return)) + + (awhen (option-ref opts 'printconf #f) (display (sxml->ansi-text ;; NOTE that this can only display config ;; items in loaded modules. @@ -192,8 +200,7 @@ ;; all configuration items. (get-configuration-documentation)) (current-output-port)) - (throw 'return) - ) + (throw 'return)) (when (option-ref opts 'version #f) (format #t "Calp version ~a~%" (@ (calp) version)) -- cgit v1.2.3