From fa1e28ac9e14c6347bfc7a29d514811e69459463 Mon Sep 17 00:00:00 2001 From: Rex Raphael Date: Sun, 6 Sep 2026 15:56:47 -0500 Subject: [PATCH] chore(example): use the current logger API in the standalone example The standalone example still constructed its logger with log.NewBeautifulLogger, which go-utils v1.3.0 keeps working as a deprecated shim. An example is the wrong place to demonstrate a deprecated constructor, so it now uses log.New(log.Config{Name: "authsome"}). Behaviour is the same either way. The comment records what that behaviour is, since it is no longer implied by the constructor's name: the format is chosen from the output, a terminal getting aligned coloured columns and anything else JSON, with FORGE_LOG_FORMAT overriding both. One line plus its comment. This is the last piece of the go-utils v1.3.0 adoption; the version bumps are already on main via 2ceff13. --- _examples/standalone/main.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/_examples/standalone/main.go b/_examples/standalone/main.go index 429dd267..ceff337b 100644 --- a/_examples/standalone/main.go +++ b/_examples/standalone/main.go @@ -46,7 +46,9 @@ import ( ) func main() { - logger := log.NewBeautifulLogger("authsome") + // Format is chosen automatically: a terminal gets aligned, coloured columns, + // anything else gets JSON. Override with FORGE_LOG_FORMAT=pretty|json. + logger := log.New(log.Config{Name: "authsome"}) // Create the in-memory store (swap with pgstore.New(db) for production). store := memory.New()