summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2024-01-03 14:22:47 -0600
committerJeff Carr <[email protected]>2024-01-03 14:22:47 -0600
commit6b25784508180c69076f53b7a4e78f85b367c902 (patch)
tree5ad4553fb8949f89b7ce9ee3f31786045a4ebbfb
parent907893ba7b4b0fbaacd4c644f678af1ac30737ee (diff)
always dump flags when requestedv0.3.1
Signed-off-by: Jeff Carr <[email protected]>
-rw-r--r--flags.go8
1 files changed, 5 insertions, 3 deletions
diff --git a/flags.go b/flags.go
index 9155c6f..4fe5516 100644
--- a/flags.go
+++ b/flags.go
@@ -42,16 +42,18 @@ func All(b bool) {
Set("ERROR", b)
Set("VERBOSE", b)
for _, f := range flags {
- Warn("All() Setting Name =", f.Name, "Subsystem =", f.Subsystem, "to b =", b, "vs", f.B)
+ Warn("All() ", "(" + f.Subsystem + ")", f.Name, "=", f.B, ":", f.Desc)
f.B = b
Warn("All() f.B is now", f.B)
}
}
+// this bypasses all checks and _always_ logs the info to STDOUT
+// is this a bad idea? Probably not....
func ListFlags() map[string][]string {
- Info("ListFlags() registered =", registered)
+ Log(true, "ListFlags() registered =", registered)
for _, f := range flags {
- Info("ListFlags() flag B =", f.B, "Name =", f.Name, "Subsystem =", f.Subsystem, "Description:", f.Desc)
+ Log(true, "ListFlags() ", "(" + f.Subsystem + ")", f.Name, "=", f.B, ":", f.Desc)
}
return registered