pipeline

package
v0.0.0-...-90889cf Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const ForceBuildPath = "/ffb5c0d8-e6ac-4965-9080-7168f473db57"

Variables

This section is empty.

Functions

func Batch

func Batch(
	ctx context.Context,
	in Queue[ChangeEvent],
	out Queue[ChangeEvent],
	batchDuration time.Duration,
) func() error

func Build

func Build(
	ctx context.Context,
	mainDir string,
	buildArgs []string,
	in Queue[ChangeEvent],
	out Queue[BuildEvent],
	rebuildFilter *filesystem.FilterTree,
	restartFilter *filesystem.FilterTree,
	bootstrapEvent *BuildEvent,
) func() error

func Run

func Run(
	ctx context.Context,
	runArgs []string,
	in Queue[BuildEvent],
	shutdownTimeout time.Duration,
) func() error

func Watch

func Watch(
	ctx context.Context,
	verbose bool,
	dirs []string,
	watchFilter *filesystem.FilterTree,
	out Queue[ChangeEvent],
	bootstrapEvent *ChangeEvent,

) func() error

Types

type BuildEvent

type BuildEvent struct {
	Path string
}

type ChangeEvent

type ChangeEvent struct {
	Paths []string
}

type Queue

type Queue[T any] chan T

func (Queue[T]) Pop

func (q Queue[T]) Pop(ctx context.Context, ptr *T) bool

func (Queue[T]) Push

func (q Queue[T]) Push(ctx context.Context, value T) bool

Jump to

Keyboard shortcuts

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