cloudflare/pint

Public

mirrored from https://github.com/cloudflare/pintAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
v0.82.1

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

cmd/pint/logger.go

18lines · modecode

1package main
2
3import (
4 "fmt"
5
6 "github.com/cloudflare/pint/internal/log"
7)
8
9func initLogger(level string, noColor bool) error {
10 l, err := log.ParseLevel(level)
11 if err != nil {
12 return fmt.Errorf("'%s' is not a valid log level", level)
13 }
14
15 log.Setup(l, noColor)
16
17 return nil
18}
19