mirror of
https://github.com/simon-ding/polaris.git
synced 2026-04-21 11:17:30 +08:00
feat: build windows dll and call dll in flutter
This commit is contained in:
@@ -15,12 +15,12 @@ var atom zap.AtomicLevel
|
||||
|
||||
const dataPath = "./data"
|
||||
|
||||
func init() {
|
||||
func InitLogger(toFile bool) {
|
||||
atom = zap.NewAtomicLevel()
|
||||
atom.SetLevel(zap.DebugLevel)
|
||||
|
||||
w := zapcore.Lock(os.Stdout)
|
||||
if os.Getenv("GIN_MODE") == "release" {
|
||||
if toFile {
|
||||
w = zapcore.AddSync(&lumberjack.Logger{
|
||||
Filename: filepath.Join(dataPath, "logs", "polaris.log"),
|
||||
MaxSize: 50, // megabytes
|
||||
|
||||
Reference in New Issue
Block a user