feat: fix agent logger display

This commit is contained in:
engigu
2026-02-09 18:28:14 +08:00
parent 6402943462
commit eb05eafb72
15 changed files with 181 additions and 118 deletions
+11
View File
@@ -104,6 +104,17 @@ func SetupFileOutput(logDir string) error {
return nil
}
// SetOutput 直接设置 Log 实例
func SetOutput(l *zap.Logger) {
Log = l
Sugar = l.Sugar()
}
// SetSugar 直接设置 Sugar 实例
func SetSugar(s *zap.SugaredLogger) {
Sugar = s
}
// SetLevel 设置日志级别
func SetLevel(level string) {
switch level {