buildinfo

package
v1.18.10 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2021 License: GPL-2.0, GPL-2.0-or-later Imports: 3 Imported by: 0

Documentation

Overview

This package provides a runtime/debug.BuildInfo Formatter. Usage,

if bi := buildinfo.New(); bi.Version() != buildinfo.Unavailable {
	fmt.Println(bi)
} else {
	fmt.Println(buildinfo.Unavailable)
}

Index

Constants

View Source
const Unavailable = "unavailable"

Variables

This section is empty.

Functions

This section is empty.

Types

type BuildInfo

type BuildInfo struct {
	*debug.BuildInfo
}

func New

func New() BuildInfo

func (BuildInfo) Format

func (bi BuildInfo) Format(f fmt.State, c rune)

func (BuildInfo) Version

func (bi BuildInfo) Version() string

Jump to

Keyboard shortcuts

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