aboutsummaryrefslogtreecommitdiffstats
path: root/debug.go
diff options
context:
space:
mode:
authorSam Anthony <sam@samanthony.xyz>2026-05-13 18:28:09 -0400
committerSam Anthony <sam@samanthony.xyz>2026-05-13 18:28:09 -0400
commit0865e2e03651dcc7be91846a6e52125e56bcde31 (patch)
treec5abe0a595e1ad26db0e4e7195ad963ca845e202 /debug.go
parent48f85453ffbe36f6c428a5d9a23b74122686b64c (diff)
downloadlulu-0865e2e03651dcc7be91846a6e52125e56bcde31.zip
poll for file validation status
Diffstat (limited to 'debug.go')
-rw-r--r--debug.go17
1 files changed, 17 insertions, 0 deletions
diff --git a/debug.go b/debug.go
new file mode 100644
index 0000000..18f4423
--- /dev/null
+++ b/debug.go
@@ -0,0 +1,17 @@
+package lulu
+
+import (
+ "log"
+ "os"
+)
+
+var (
+ Debug = false // print debug info to stdout
+ debugLog = log.New(os.Stderr, "DEBUG ", log.LstdFlags|log.Llongfile)
+)
+
+func debugf(format string, a ...any) {
+ if Debug {
+ debugLog.Printf(format, a...)
+ }
+}