fix(workflow): use the dev version of the web for beta releases (#7862)

* fix(workflow): use dev version of the web for beta releases

* chore(config): check version string by prefix
This commit is contained in:
Jealous
2025-01-23 22:49:35 +08:00
committed by GitHub
parent 11b6a6012f
commit c2633dd443
4 changed files with 18 additions and 5 deletions

View File

@ -50,7 +50,7 @@ func InitConfig() {
log.Fatalf("load config error: %+v", err)
}
LastLaunchedVersion = conf.Conf.LastLaunchedVersion
if conf.Version != "dev" || LastLaunchedVersion == "" {
if strings.HasPrefix(conf.Version, "v") || LastLaunchedVersion == "" {
conf.Conf.LastLaunchedVersion = conf.Version
}
// update config.json struct

View File

@ -5,6 +5,7 @@ import (
"github.com/alist-org/alist/v3/internal/bootstrap/patch"
"github.com/alist-org/alist/v3/internal/conf"
"github.com/alist-org/alist/v3/pkg/utils"
"strings"
)
var LastLaunchedVersion = ""
@ -38,7 +39,7 @@ func compareVersion(majorA, minorA, patchNumA, majorB, minorB, patchNumB int) bo
}
func InitUpgradePatch() {
if conf.Version == "dev" {
if !strings.HasPrefix(conf.Version, "v") {
return
}
if LastLaunchedVersion == conf.Version {