context

package
v1.3.9 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApplicationContext

type ApplicationContext interface {
	// GetRunId is the current Ankor CLI run id, which differs in each
	// run of the CLI. This can be used to save certain information
	// during the run.
	GetRunId() string
	SetContextWithValue(ctx ctx.Context, key any, value any)
	GetContext() ctx.Context

	// Logger is the currently used logger
	Logger() log.Logger
	// Config is the loaded Ankor config
	Config() config.Config
	Version() string
	GetTemplateFs() embed.FS
	WithTemplateFs(fs embed.FS) ApplicationContext
	WithLogger(logger log.Logger) ApplicationContext
	WithConfig(conf config.Config) ApplicationContext
	WithVersion(version string) ApplicationContext
	AttachGlobalFolders(dirs util.Dirs) ApplicationContext
	RootFolder() util.Dirs
	GetRuntime() Runtime
	GetDate() time.Time
}

func NewContext

func NewContext() ApplicationContext

type Runtime

type Runtime struct {
	Goos   string
	Goarch string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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