build

package
v0.0.0-...-7b96089 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2023 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

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

func NewBuilder

func NewBuilder(project project.Project, cfg Configuration) *Builder

func (*Builder) Build

func (b *Builder) Build(ctx context.Context) (*Result, error)

type Configuration

type Configuration struct {
	OutputDirectory string
	BuildDirectory  string

	BuildSteps []Step

	MaxSteps  int
	MaxEpochs int
}

func (*Configuration) GetBuildPath

func (bd *Configuration) GetBuildPath(p ...string) string

func (*Configuration) GetOutputPath

func (bd *Configuration) GetOutputPath(p ...string) string

func (*Configuration) ResolveBuildDir

func (bd *Configuration) ResolveBuildDir(p ...string) string

func (*Configuration) ResolveBuildFile

func (bd *Configuration) ResolveBuildFile(p ...string) string

func (*Configuration) ResolveOutputDir

func (bd *Configuration) ResolveOutputDir(p ...string) string

func (*Configuration) ResolveOutputFile

func (bd *Configuration) ResolveOutputFile(p ...string) string

type Context

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

func (*Context) Build

func (bctx *Context) Build(ctx context.Context) (*Result, error)

func (*Context) Close

func (bctx *Context) Close()

func (*Context) Config

func (bctx *Context) Config() Configuration

func (*Context) Log

func (bctx *Context) Log() *Log

func (*Context) Project

func (bctx *Context) Project() project.Project

func (*Context) ReportError

func (bctx *Context) ReportError(err error)

type Log

type Log struct {
}

func NewLog

func NewLog(outputFile string) (*Log, error)

func (*Log) Close

func (l *Log) Close() error

func (*Log) Error

func (l *Log) Error(err error)

type Result

type Result struct {
	ChangeCount int
	Errors      []error

	TotalSteps  int
	TotalEpochs int
}

type Step

type Step interface {
	Process(ctx context.Context, bctx *Context) (StepResult, error)
}

type StepResult

type StepResult struct {
	ChangeCount int

	Errors []error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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