Files
open-im-server/cmd/cmdutils/main.go
T

22 lines
551 B
Go
Raw Normal View History

2023-02-23 18:20:45 +08:00
package main
import (
2023-02-23 19:15:30 +08:00
"OpenIM/internal/task"
2023-02-23 19:41:44 +08:00
"OpenIM/pkg/common/config"
2023-02-23 18:20:45 +08:00
"flag"
"fmt"
"time"
)
func main() {
2023-02-24 17:42:01 +08:00
if err := config.InitConfig(); err != nil {
panic(err.Error())
}
2023-02-23 19:15:30 +08:00
var userID = flag.String("user_id", "", "userID to clear msg and reset seq")
var superGroupID = flag.String("super_group_id", "", "superGroupID to clear msg and reset seq")
var fixAllSeq = flag.Bool("fix_all_seq", false, "fix seq")
2023-02-23 18:20:45 +08:00
flag.Parse()
2023-02-23 19:15:30 +08:00
fmt.Println(time.Now(), "start cronTask", *userID, *superGroupID)
task.FixSeq(*userID, *superGroupID, *fixAllSeq)
2023-02-23 18:20:45 +08:00
}