version

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package version exposes build-time version metadata.

The variables Version, GitCommit, and BuildTime are intended to be set at compile time via -ldflags:

go build -ldflags "-X github.com/Azure/unbounded/internal/version.Version=v1.0.0
                    -X github.com/Azure/unbounded/internal/version.GitCommit=abc1234
                    -X github.com/Azure/unbounded/internal/version.BuildTime=2026-04-21T00:00:00Z"

Index

Constants

This section is empty.

Variables

View Source
var BuildTime = "unknown"

BuildTime is the UTC timestamp the binary was built at (RFC 3339). Set at build time; defaults to "unknown" for local builds.

View Source
var GitCommit = "unknown"

GitCommit is the git commit SHA the binary was built from. Set at build time; defaults to "unknown" for local builds.

View Source
var Version = "dev"

Version is the semantic version of the binary. Set at build time; defaults to "dev" for local builds.

Functions

func Command

func Command() *cobra.Command

Command returns a cobra command that prints the version string.

func String

func String() string

String returns a human-readable version string.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL