mirror of
https://github.com/zrepl/zrepl.git
synced 2024-11-29 11:55:03 +01:00
18 lines
280 B
Go
18 lines
280 B
Go
package trace
|
|
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
|
|
"github.com/zrepl/zrepl/util/envconst"
|
|
)
|
|
|
|
var debugEnabled = envconst.Bool("ZREPL_TRACE_DEBUG_ENABLED", false)
|
|
|
|
func debug(format string, args ...interface{}) {
|
|
if !debugEnabled {
|
|
return
|
|
}
|
|
fmt.Fprintf(os.Stderr, format+"\n", args...)
|
|
}
|