telemetry

package
v0.2.5 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Find

func Find(val string) bool

Find compared user input string with accepted values

func GetContextProperties

func GetContextProperties(ctx context.Context) map[string]interface{}

GetContextProperties returns current property state

func GetContextProperty added in v0.2.2

func GetContextProperty(ctx context.Context, property string) (string, error)

GetContextProperty returns single property state

func GetTelemetryConsent

func GetTelemetryConsent() bool

func NewContext

func NewContext(ctx context.Context) context.Context

NewContext creates a New Context

func SetClient

func SetClient(ctx context.Context, value string)

SetClient sets cient property: Ex: terminal, jenkins, etc

func SetEcosystem

func SetEcosystem(ctx context.Context, value string)

SetEcosystem sets ecosystem property

func SetError

func SetError(err error) string

SetError replaces sensitive data from error recording

func SetExitCode

func SetExitCode(ctx context.Context, value int)

SetExitCode sets exit code property

func SetFlag

func SetFlag(ctx context.Context, flag string, value bool)

SetFlag records Json, verbose flags

func SetManifest

func SetManifest(ctx context.Context, value string)

SetManifest sets manifest name property

func SetSnykTokenAssociation

func SetSnykTokenAssociation(ctx context.Context, value bool)

SetSnykTokenAssociation sets synk-token-associated property

func SetVulnerability

func SetVulnerability(ctx context.Context, value int)

SetVulnerability sets total vulnerability found property

Types

type Properties

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

Properties maintain state of Telemetry event Properties.

Jump to

Keyboard shortcuts

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