build

package
v0.1.0-alpha.71 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2026 License: Apache-2.0 Imports: 16 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUserCancelled = errors.New("user cancelled")

Functions

func PullOutput

func PullOutput(output, url, ref, branch, targetDir string, targetGroup console.Group) error

PullOutput handles downloading or cloning a build target output

func PullOutputWithRetry

func PullOutputWithRetry(output, url, ref, branch, targetDir string, targetGroup console.Group, maxRetries int) error

PullOutputWithRetry wraps PullOutput with exponential backoff retry logic maxRetries: maximum number of retry attempts (0 means no retries, just one attempt) Uses 1s initial delay with exponential backoff, clamped at 30s max delay

func View

func View(build stainless.Build, downloads map[stainless.Target]DownloadStatus) string

func ViewBuildPipeline

func ViewBuildPipeline(build stainless.Build, target stainless.Target, downloads map[stainless.Target]DownloadStatus) string

View renders the build pipeline for a target

func ViewStepSymbol

func ViewStepSymbol(status, conclusion string) string

ViewStepSymbol returns a colored symbol for a build step status

Types

type DownloadMsg

type DownloadMsg struct {
	Target stainless.Target
	// One of "not_started", "in_progress", "completed"
	Status string
	// One of "success", "failure',
	Conclusion string
	Error      string
}

type DownloadStatus

type DownloadStatus struct {
	Status string // one of "not_started" "in_progress" "completed"
	// One of "success", "failure', or empty if Status not "completed"
	Conclusion string
	Path       string
	Error      string // Error message if Conclusion is "failure"
}

type ErrorMsg

type ErrorMsg error

type FetchBuildMsg

type FetchBuildMsg stainless.Build

type Model

type Model struct {
	stainless.Build // Current build. This component will keep fetching it until the build is completed. A zero value is permitted.

	Client    stainless.Client
	Ctx       context.Context
	Branch    string                              // Optional branch name for git checkout
	Downloads map[stainless.Target]DownloadStatus // When a BuildTarget has a commit available, this target will download it, if it has been specified in the initialization.
	Err       error                               // This will be populated if the model concludes with an error
}

func NewModel

func NewModel(client stainless.Client, ctx context.Context, build stainless.Build, branch string, downloadPaths map[stainless.Target]string) Model

func (Model) Init

func (m Model) Init() tea.Cmd

func (Model) Update

func (m Model) Update(msg tea.Msg) (Model, tea.Cmd)

func (Model) View

func (m Model) View() string

type TickMsg

type TickMsg time.Time

Jump to

Keyboard shortcuts

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