matrix

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CartesianProduct

func CartesianProduct(m map[string][]string) []map[string]string

Types

type Entry

type Entry map[string]string

func (Entry) BriefString

func (m Entry) BriefString() string

BriefString return all values concatenated with slash

func (Entry) Equals

func (m Entry) Equals(a map[string]string) bool

func (Entry) Match

func (m Entry) Match(a map[string]string) bool

func (Entry) String

func (m Entry) String() string

type Spec

type Spec struct {
	rs.BaseField

	Include []*specItem `yaml:"include"`
	Exclude []*specItem `yaml:"exclude"`

	// TODO: validate kernel and arch values to ensure
	// 		 tools get expected value set
	Kernel []string `yaml:"kernel"`
	Arch   []string `yaml:"arch"`

	// catch other matrix fields
	Custom map[string][]string `rs:"other"`
}

func (*Spec) GenerateEntries

func (mc *Spec) GenerateEntries(
	matchFilter map[string][]string,
	hostKernel, hostArch string,
) []Entry

Jump to

Keyboard shortcuts

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