Documentation
¶
Overview ¶
Package logutil provides structured, grep-friendly logging to stderr.
Every message is prefixed with an ISO 8601 timestamp and a level tag (ERROR, WARN, INFO, DEBUG). When a project identifier is available, the "P" variants (ErrorP, WarnP, …) insert it as [project] after the level.
Output format:
2026-03-20T10:32:00-07:00 ERROR: synapses: something broke: file not found 2026-03-20T10:32:00-07:00 INFO: [abc123] synapses: project ready
This is NOT a full structured logging framework — it is a minimal, grep-friendly convention that enables `grep ERROR:` for incident triage.
Index ¶
- func Debug(format string, args ...interface{})
- func DebugP(project string, format string, args ...interface{})
- func Error(format string, args ...interface{})
- func ErrorP(project string, format string, args ...interface{})
- func Info(format string, args ...interface{})
- func InfoP(project string, format string, args ...interface{})
- func Warn(format string, args ...interface{})
- func WarnP(project string, format string, args ...interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Debug ¶
func Debug(format string, args ...interface{})
Debug logs a DEBUG-level message to stderr with timestamp.
func Error ¶
func Error(format string, args ...interface{})
Error logs an ERROR-level message to stderr with timestamp.
func Info ¶
func Info(format string, args ...interface{})
Info logs an INFO-level message to stderr with timestamp.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.