chore & auto dep

This commit is contained in:
josc146
2023-05-20 23:34:33 +08:00
parent 9076ff3fd7
commit b8f7582513
15 changed files with 291 additions and 53 deletions

View File

@@ -5,9 +5,10 @@ import (
"net/http"
"os"
"os/exec"
"runtime"
"github.com/minio/selfupdate"
"github.com/wailsapp/wails/v2/pkg/runtime"
wruntime "github.com/wailsapp/wails/v2/pkg/runtime"
)
// App struct
@@ -46,6 +47,10 @@ func (a *App) UpdateApp(url string) (broken bool, err error) {
return false, err
}
exec.Command(name, os.Args[1:]...).Start()
runtime.Quit(a.ctx)
wruntime.Quit(a.ctx)
return false, nil
}
func (a *App) GetPlatform() string {
return runtime.GOOS
}