Read the architecture at run time instead of a Buildarch ldflag (closes #259)
Check / check (pull_request) Skipped
Check / check (pull_request) Skipped
The Makefile no longer passes the architecture to the linker. The Buildarch variable in main and the field and setter in globals are gone; the startup log line reports runtime.GOARCH as `arch`. CONVENTIONS.md drops Buildarch from its main, globals, logger and Makefile examples, as the sneak/prompts conventions do. Model: opus-5-5
This commit is contained in:
+2
-4
@@ -25,15 +25,13 @@ import (
|
||||
// Build-time variables injected by linker flags (-ldflags).
|
||||
// These must be exported package-level variables for the build system.
|
||||
var (
|
||||
Appname = "upaas" //nolint:gochecknoglobals // build-time variable
|
||||
Version string //nolint:gochecknoglobals // build-time variable
|
||||
Buildarch string //nolint:gochecknoglobals // build-time variable
|
||||
Appname = "upaas" //nolint:gochecknoglobals // build-time variable
|
||||
Version string //nolint:gochecknoglobals // build-time variable
|
||||
)
|
||||
|
||||
func main() {
|
||||
globals.SetAppname(Appname)
|
||||
globals.SetVersion(Version)
|
||||
globals.SetBuildarch(Buildarch)
|
||||
|
||||
fx.New(
|
||||
fx.Provide(
|
||||
|
||||
Reference in New Issue
Block a user