Help us shape the future of Go! Take the 2026 Go Developer Survey

dev

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const DEFAULT_TIMEOUT = 1
View Source
const NO_TIMEOUT = -1
View Source
const STDIN = "0"

Variables

View Source
var RunInteractively bool = true // default to run dev command interactively

Functions

func DevGetResources

func DevGetResources(ctx context.Context, validationBytes []byte, spinner *message.Spinner) (types.DomainResources, error)

func DevLintCommand added in v0.4.3

func DevLintCommand(inputFiles []string) []oscalValidation.ValidationResult

func DevValidate

func DevValidate(ctx context.Context, validationBytes []byte, resourcesBytes []byte, spinner *message.Spinner) (lulaValidation types.LulaValidation, err error)

DevValidate reads a validation manifest and converts it to a LulaValidation struct, then validates it Returns the LulaValidation struct and any error encountered

func Include

func Include(rootCmd *cobra.Command)

Include adds the tools command to the root command.

func ReadValidation added in v0.4.0

func ReadValidation(cmd *cobra.Command, spinner *message.Spinner, path string, timeout int) ([]byte, error)

ReadValidation reads the validation yaml file and returns the validation bytes

func RunSingleValidation added in v0.4.0

func RunSingleValidation(ctx context.Context, validationBytes []byte, opts ...types.LulaValidationOption) (lulaValidation types.LulaValidation, err error)

RunSingleValidation runs a single validation

Types

type LintFlags added in v0.4.3

type LintFlags struct {
	InputFiles []string // -f --input-files
	ResultFile string   // -r --result-file
}

type ValidateFlags

type ValidateFlags struct {
	ExpectedResult bool   // -e --expected-result
	ResourcesFile  string // -r --resources-file
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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