stableversion

package
v0.0.0-...-e560ebb Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2021 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddUpdatedCros

func AddUpdatedCros(old, updated []*sv.StableCrosVersion) []*sv.StableCrosVersion

AddUpdatedCros add and update the new cros stable version to old.

func AddUpdatedFirmware

func AddUpdatedFirmware(old, updated []*sv.StableFirmwareVersion) []*sv.StableFirmwareVersion

AddUpdatedFirmware add and update the new firmware stable version to old.

func CompareCrOSVersions

func CompareCrOSVersions(v1, v2 string) (int, error)

CompareCrOSVersions compares two cros versions' number.

Return:

1 if v1 > v2
0 if v1 == v2
-1 if v1 < v2

func FallbackBuildTargetKey

func FallbackBuildTargetKey(buildTarget string) string

FallbackBuildTargetKey creates the key based on the given build target This kind of key should only ever be used as a fallback when looking up a stable version.

func JoinBuildTargetModel

func JoinBuildTargetModel(buildTarget string, model string) (string, error)

JoinBuildTargetModel -- join a buildTarget string and a model string to produce a combined key

func ParseCrOSVersion

func ParseCrOSVersion(v string) (int, int, int, int, error)

ParseCrOSVersion takes a version string and extracts version info

func ParseFaftVersion

func ParseFaftVersion(fv string) (string, int, int, int, int, error)

ParseFaftVersion takes a version string and extracts version info

func ParseFirmwareVersion

func ParseFirmwareVersion(s string) (string, string, int, int, string, error)

ParseFirmwareVersion takes a read-write firmware version and extracts semantically meaningful elements.

func SerializeCrOSVersion

func SerializeCrOSVersion(release, tip, branch, branchBranch int) string

SerializeCrOSVersion takes a CrOSVersion specification and produces a string in the canonical format.

func SerializeFaftVersion

func SerializeFaftVersion(platform string, release, tip, branch, branchBranch int) string

SerializeFaftVersion takes arguments describing a faft version and produces a string in the canonical format.

func SerializeFirmwareVersion

func SerializeFirmwareVersion(company string, platform string, tip int, branch int, branchBranch int) string

SerializeFirmwareVersion takes a list of components of a RWFirmwareVersion

func SortSV

func SortSV(s *sv.StableVersions)

SortSV sorts all the individual entries in a stable version config file.

func ValidateCrOSVersion

func ValidateCrOSVersion(v string) error

ValidateCrOSVersion checks that a CrOSVersion describes a sensible version such as "R76-12239.46.5"

func ValidateFaftVersion

func ValidateFaftVersion(v string) error

ValidateFaftVersion checks that a given faft version is well-formed such as "octopus-firmware/R72-11297.75.0"

func ValidateFirmwareVersion

func ValidateFirmwareVersion(r string) error

ValidateFirmwareVersion checks whether a string is a valid read-write firmware version. e.g. Google_Rammus.11275.41.0

func ValidateJoinBuildTargetModel

func ValidateJoinBuildTargetModel(buildTarget string, model string) error

ValidateJoinBuildTargetModel -- checks that a buildTarget and model are valid The model is explicitly allowed to be empty.

func WriteSVToString

func WriteSVToString(s *sv.StableVersions) (string, error)

WriteSVToString marshals stable version information into a string.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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