Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Event ¶ added in v3.35.0
type Event struct {
Type EventType `json:"type"`
Time time.Time `json:"timestamp"`
PreflightID string `json:"preflight_id,omitempty"`
// Title is the primary status text shown in the TTY dynamic area.
Title string `json:"title,omitempty"`
// Detail is supplementary information printed to the scrollback log.
Detail string `json:"detail,omitempty"`
Pipeline string `json:"pipeline,omitempty"`
BuildNumber int `json:"build_number,omitempty"`
BuildURL string `json:"build_url,omitempty"`
BuildState string `json:"build_state,omitempty"`
Jobs *watch.JobSummary `json:"jobs,omitempty"`
// Job is set for job_failure events.
Job *buildkite.Job `json:"job,omitempty"`
// FailedJobs is set for build_summary events when the build failed. Contains hard-failed jobs only (soft failures excluded).
FailedJobs []buildkite.Job `json:"failed_jobs,omitempty"`
// PassedJobs is set for build_summary events when the build passed and has 10 or fewer jobs.
PassedJobs []buildkite.Job `json:"passed_jobs,omitempty"`
// Duration is set for build_summary events. Total elapsed time of the preflight run.
Duration time.Duration `json:"duration_ns,omitempty"`
// TestFailures is set for test_failure events.
TestFailures []buildkite.BuildTest `json:"test_failures,omitempty"`
}
Event is the single data model emitted by a preflight run. Renderers project events differently by output mode (TTY, text, JSON).
type EventType ¶ added in v3.35.0
type EventType string
EventType identifies the kind of preflight event.
type PreflightCmd ¶
type PreflightCmd struct {
Pipeline string `help:"The pipeline to build. This can be a {pipeline slug} or in the format {org slug}/{pipeline slug}." short:"p"`
Watch bool `help:"Watch the build until completion." default:"true" negatable:""`
Interval float64 `help:"Polling interval in seconds when watching." default:"2"`
NoCleanup bool `help:"Skip deleting the remote preflight branch after the build finishes."`
Text bool `help:"Use plain text output instead of interactive terminal UI." xor:"output"`
JSON bool `help:"Emit one JSON object per event (JSONL)." xor:"output"`
}
func (*PreflightCmd) Help ¶
func (c *PreflightCmd) Help() string
func (*PreflightCmd) Run ¶
func (c *PreflightCmd) Run(kongCtx *kong.Context, globals cli.GlobalFlags) error
Click to show internal directories.
Click to hide internal directories.