File: doc.go

package info (click to toggle)
golang-github-lestrrat-go-pdebug 0.0~git20180220.0.569c974-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 108 kB
  • sloc: makefile: 2
file content (15 lines) | stat: -rw-r--r-- 746 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// Package pdebug provides tools to produce debug logs the way the author
// (Daisuke Maki a.k.a. lestrrat) likes. All of the functions are no-ops
// unless you compile with the `-tags debug` option.
//
// When you compile your program with `-tags debug`, no trace is displayed,
// but the code enclosed within `if pdebug.Enabled { ... }` is compiled in.
// To show the debug trace, set the PDEBUG_TRACE environment variable to
// true (or 1, or whatever `strconv.ParseBool` parses to true)
//
// If you want to show the debug trace regardless of an environment variable,
// for example, perhaps while you are debugging or running tests, use the
// `-tags debug0` build tag instead. This will enable the debug trace
// forcefully
package pdebug