Skip to content

Commit 3acc6bc

Browse files
committed
fix: logging level
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
1 parent 358a7b2 commit 3acc6bc

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

cmd/root.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66

77
"github.com/loft-sh/devpod-provider-dockerless/pkg/version"
88
"github.com/loft-sh/log"
9+
"github.com/sirupsen/logrus"
910
"github.com/spf13/cobra"
1011
)
1112

@@ -18,6 +19,10 @@ func NewRootCmd() *cobra.Command {
1819
SilenceUsage: true,
1920

2021
PersistentPreRunE: func(cobraCmd *cobra.Command, args []string) error {
22+
if os.Getenv("DEVPOD_DEBUG") == "true" {
23+
log.Default.SetLevel(logrus.DebugLevel)
24+
}
25+
2126
log.Default.MakeRaw()
2227

2328
return nil

0 commit comments

Comments
 (0)