mirror of
https://github.com/GopeedLab/gopeed.git
synced 2026-11-08 17:40:28 +00:00
feat: new version check (#102)
This commit is contained in:
1 parent
701ea59035
commit
33f6325bf7
19 files changed
+235
-91
No files matched your search
+1
-12
@@ -5,11 +5,8 @@ package main
|
||||
|
||||
import (
|
||||
"embed"
|
||||
"fmt"
|
||||
"github.com/GopeedLab/gopeed/pkg/rest"
|
||||
"github.com/GopeedLab/gopeed/pkg/rest/model"
|
||||
"io/fs"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
//go:embed banner.txt
|
||||
@@ -30,13 +27,5 @@ func main() {
|
||||
WebEnable: true,
|
||||
WebFS: sub,
|
||||
}
|
||||
fmt.Println(banner)
|
||||
srv, listener, err := rest.BuildServer(cfg)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
fmt.Printf("Server start success on http://%s\n", listener.Addr().String())
|
||||
if err := srv.Serve(listener); err != nil && err != http.ErrServerClosed {
|
||||
panic(err)
|
||||
}
|
||||
cmd.Start(cfg)
|
||||
}
|
||||
Reference in new issue
Block a user