refactor!: retire wails.json, config.yml is the version source
- version.go (generated, never hand-edited) carries the compiled-in version; app.go drops the wails.json embed plus the gjson dependency - make release bumps config.yml and regenerates version.go in one commit; the re-run-safe guards from the 1.99.1 cycle carry over - release guard reads config.yml; CI CLI pin and cache key move to beta.22 to match the lockstep above - release wrapper and config NOTE comments updated; deletion proof: wails3 build green plus a dev boot reaching the connected state with the file absent (the one cold-boot failure reproduced as a Vite 8 cold-start vs app retry race, cleared by rerunning warm)
This commit is contained in:
@@ -1,16 +1,11 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
_ "embed"
|
||||
"strings"
|
||||
|
||||
"github.com/tidwall/gjson"
|
||||
"github.com/wailsapp/wails/v3/pkg/application"
|
||||
)
|
||||
|
||||
//go:embed wails.json
|
||||
var wailsJSON string
|
||||
|
||||
// App struct
|
||||
type App struct {
|
||||
app *application.App
|
||||
@@ -21,9 +16,10 @@ func NewApp(app *application.App) *App {
|
||||
return &App{app: app}
|
||||
}
|
||||
|
||||
// appVersion reads the product version from wails.json.
|
||||
// appVersion is the release version, stamped into version.go by
|
||||
// `make release` from build/config.yml.
|
||||
func appVersion() string {
|
||||
return gjson.Get(wailsJSON, "info.productVersion").String()
|
||||
return appVersionString
|
||||
}
|
||||
|
||||
// appTitle is the window title: "AniTrack <version>".
|
||||
|
||||
Reference in New Issue
Block a user