main
When VERSION isn't set with -ldflags, use debug.BuildInfo's Main.Version, which Go 1.24+ fills from git: the tag on a tagged commit, or a pseudo-version on an untagged one. A "+dirty" suffix is removed; the modified state is reported by the new Info.Modified field and the existing "-M" suffix in Version(). "(devel)" or no build info keeps "dev-snapshot". The decision is in resolveVersion() so it can be tested directly. CheckVersion now compares a pseudo-version after a release tag as the release it leads up to (v1.2.4-0.<time>-<rev> as v1.2.4), so dev builds of current code pass minimum-version checks while builds from older branches still fail. A pseudo-version with no tag history passes, like "dev-snapshot". Also fix Version() never filling its cache: a local variable shadowed the package-level one.
Common library for the NTP Pool project with shared infrastructure components.
Packages
- apitls - TLS setup for NTP Pool internal services with embedded CA
- config - NTP Pool project configuration with environment variables
- ekko - Enhanced Echo web framework with observability middleware
- health - Standalone health check HTTP server
- kafka - Kafka client wrapper with TLS support
- logger - Structured logging with OpenTelemetry integration
- metricsserver - Prometheus metrics HTTP server
- timeutil - JSON-serializable duration types
- tracing - OpenTelemetry distributed tracing setup
- types - Shared data structures for NTP Pool
- ulid - Thread-safe ULID generation
- version - Build metadata and version information
- xff/fastlyxff - Fastly CDN IP range management
Languages
Go
99.4%
Shell
0.5%