version

package
v1.8.2-beta6 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package version contains version information for Functional Conformance Suite.

Index

Constants

View Source
const (

	//FullVersion -  Checker is the full string version of Conformance Suite.
	FullVersion = major + "." + minor + "." + patch

	// Prerelease - is pre-release marker for the version. If this is "" (empty string)
	// then it means that it is a final release. Otherwise, this is a pre-release
	// such as "alpha", "beta", "rc1", etc.
	Prerelease          = ""
	GitHubAPIRepository = "https://api.github.com/repos/OpenBankingUK/conformance-suite/tags"
)

Checker returns the semantic version (see http://semver.org).

Variables

This section is empty.

Functions

This section is empty.

Types

type Checker

type Checker interface {
	GetHumanVersion() string
	VersionFormatter(version string) (string, error)
	UpdateWarningVersion(version string) (string, bool, error)
}

Checker defines functionality to reason about the current version of the software and if updates are available

type GitHub

type GitHub struct {
	// contains filtered or unexported fields
}

GitHub helper with capability to get release versions from source control repository

func NewGitHub

func NewGitHub(bitBucketAPIRepository string) GitHub

NewGitHub returns a new instance of Checker.

func (GitHub) GetHumanVersion

func (v GitHub) GetHumanVersion() string

GetHumanVersion composes the parts of the version in a way that's suitable for displaying to humans.

func (GitHub) UpdateWarningVersion

func (v GitHub) UpdateWarningVersion(version string) (string, bool, error)

UpdateWarningVersion takes a version number and checks it against the latest tag version on GitHub, if a newer version is found it returns a message and bool value that can be used to inform a user a newer version is available for download.

func (GitHub) VersionFormatter

func (v GitHub) VersionFormatter(version string) (string, error)

VersionFormatter takes a string version number and returns just the numeric parts. This function is used when trying to compare two string versions that 'could' have non numerical properties.

type Tag

type Tag struct {
	Name string `json:"name"`
}

Tag structure used map response of tags.

func (Tag) LessThan

func (t Tag) LessThan(subject string) bool

type TagsAPIResponse

type TagsAPIResponse struct {
	TagList []Tag
}

TagsAPIResponse structure to map response.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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