You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
396 B
Go
27 lines
396 B
Go
package main
|
|
|
|
import (
|
|
"live-gateway/bilibili"
|
|
"live-gateway/config"
|
|
"live-gateway/pkg/logger"
|
|
"sync"
|
|
)
|
|
|
|
func main() {
|
|
_ = logger.InitLogger(&config.Config.Log.File, &config.Config.Log.Console)
|
|
defer logger.Sync()
|
|
|
|
var wg sync.WaitGroup
|
|
|
|
bLive := bilibili.NewLiveBilibili()
|
|
wg.Add(1)
|
|
go func() {
|
|
if err := bLive.Serve(); err != nil {
|
|
wg.Done()
|
|
panic(err)
|
|
}
|
|
}()
|
|
|
|
wg.Wait()
|
|
}
|