Context
go install github.com/timimsms/cu/cmd/cu@latest now works (verified post-v0.1.0) but the resulting binary reports cu version dev — go install doesn't apply the ldflags that Make/GoReleaser set.
Suggested fix
In internal/version, when Version == "dev", fall back to runtime/debug.ReadBuildInfo(): info.Main.Version carries the module version (v0.1.0) for go install builds, and the vcs.revision/vcs.time build settings cover commit/date. This is the same pattern gh and other Go CLIs use, and it keeps ldflags as the primary source for released binaries.
Context
go install github.com/timimsms/cu/cmd/cu@latestnow works (verified post-v0.1.0) but the resulting binary reportscu version dev—go installdoesn't apply the ldflags that Make/GoReleaser set.Suggested fix
In
internal/version, whenVersion == "dev", fall back toruntime/debug.ReadBuildInfo():info.Main.Versioncarries the module version (v0.1.0) forgo installbuilds, and thevcs.revision/vcs.timebuild settings cover commit/date. This is the same pattern gh and other Go CLIs use, and it keeps ldflags as the primary source for released binaries.