step011: run command

This commit is contained in:
root
2024-03-20 19:14:31 -07:00
commit 2893ff3c21
11 changed files with 234 additions and 0 deletions

19
internal/log/log.go Normal file
View File

@ -0,0 +1,19 @@
package log
import (
"os"
"github.com/sirupsen/logrus"
"github.com/spf13/cast"
)
func init() {
if cast.ToBool(os.Getenv("UPOD_DEBUG")) {
logrus.SetLevel(logrus.DebugLevel)
}
}
func Debug(msg string, args ...any) {
logrus.Debugf(msg, args...)
}