monitor

package
v0.2.1-alpha Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2026 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RunningBuildsMonitor

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

RunningBuildsMonitor polls ListRunningBuilds every 1s and emits RunningBuildsUpdatedMsg. It tracks arrivals/departures and fetches final build status for builds that just left the running set.

Usage: call Init() from App.Init(), and pass every incoming message to HandleMsg() at the top of App.Update().

func NewRunningBuildsMonitor

func NewRunningBuildsMonitor(client jenkins.JenkinsClient, store *cache.Store) *RunningBuildsMonitor

NewRunningBuildsMonitor creates a monitor. store may be nil in tests.

func (*RunningBuildsMonitor) HandleMsg

func (m *RunningBuildsMonitor) HandleMsg(msg tea.Msg) (bool, []tea.Cmd)

HandleMsg should be called for every message in App.Update(). Returns (true, cmds) when the message is an internal monitor message and was fully consumed. The caller must not process the message further.

func (*RunningBuildsMonitor) Init

func (m *RunningBuildsMonitor) Init() tea.Cmd

Init returns the first poll command. Call from App.Init().

Jump to

Keyboard shortcuts

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