version

package
v0.10.1 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2025 License: Apache-2.0 Imports: 6 Imported by: 1 module, 1 package

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package version Gets information about releases and build.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Build

type Build struct {
	Builders  []string   `json:"builders"`
	Revisions []Revision `json:"revisions"`
}

Build information.

func GetBuild

func GetBuild() (*Build, error)

GetBuild gets build information.

func GetBuildWithContext added in v0.10.0

func GetBuildWithContext(ctx context.Context) (*Build, error)

GetBuildWithContext gets build information.

type File

type File struct {
	Filename string `json:"filename"`
	OS       string `json:"os"`
	Arch     string `json:"arch"`
	Version  string `json:"version"`
	SHA256   string `json:"sha256"`
	Size     int    `json:"size"`
	Kind     string `json:"kind"`
}

File represents a file on the golang.org downloads page.

type Release

type Release struct {
	Version string `json:"version"`
	Stable  bool   `json:"stable"`
	Files   []File `json:"files"`
}

Release represents a release on the golang.org downloads page.

func GetReleases

func GetReleases(all bool) ([]Release, error)

GetReleases gets build information.

func GetReleasesWithContext added in v0.10.0

func GetReleasesWithContext(ctx context.Context, all bool) ([]Release, error)

GetReleasesWithContext gets build information.

type Revision

type Revision struct {
	Repo       string    `json:"repo"`
	Revision   string    `json:"revision"`
	Date       time.Time `json:"date"`
	Branch     string    `json:"branch"`
	Author     string    `json:"author"`
	Desc       string    `json:"desc"`
	Results    []string  `json:"results"`
	GoRevision string    `json:"goRevision,omitempty"`
	GoBranch   string    `json:"goBranch,omitempty"`
}

Revision information.

Jump to

Keyboard shortcuts

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