util

package
v0.13.0-alpha.2 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2024 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Index

Constants

View Source
const (
	StackYAMLFile     = "stack.yaml"
	StackYAMLTemplate = `# The metadata information of the stack. 
name: %s`

	KCLModFile         = "kcl.mod"
	KCLModFileTemplate = `` /* 210-byte string literal not displayed */

	MainKCLFile         = "main.k"
	MainKCLFileTemplate = `` /* 421-byte string literal not displayed */

)

Variables

View Source
var (
	ErrStackNameEmpty   = errors.New("the stack name must not be empty")
	ErrStackNameTooLong = errors.New("the stack name must be less than 100 characters")
	ErrStackNameInvalid = errors.New("the stack name can only contain alphanumeric, hyphens, underscores, and periods")
	ErrNotEmptyDir      = errors.New("not empty existing target directory for stack creation")
)

Functions

func CreateWithRefStack

func CreateWithRefStack(stackName, stackDir, refStackDir string) error

CreateWithRefStack creates a new stack with referenced stack if specified.

func ValidateProjectDir

func ValidateProjectDir(dir string) error

ValidateProjectDir returns whether the target project directory is valid or not.

func ValidateRefStackDir

func ValidateRefStackDir(dir string) error

ValidateRefStackDir returns whether the referenced stack directory is valid or not.

func ValidateStackDir

func ValidateStackDir(dir string) error

ValidateStackDir returns whether the target stack directory is valid or not.

func ValidateStackName

func ValidateStackName(name string) error

ValidateStackName returns whether the stack name is valid or not.

Types

This section is empty.

Jump to

Keyboard shortcuts

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