notify

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: May 13, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DesktopConfig

type DesktopConfig struct {
	Enabled         bool
	CooldownSeconds int
	QueueSize       int
	SendTimeoutMs   int
}

type EventType

type EventType string
const (
	EventApprovalRequired EventType = "approval_required"
	EventRunCompleted     EventType = "run_completed"
	EventRunFailed        EventType = "run_failed"
	EventRunCanceled      EventType = "run_canceled"
)

type Message

type Message struct {
	Event EventType
	Title string
	Body  string
	Key   string
}

func BuildApprovalRequiredMessage

func BuildApprovalRequiredMessage(command, reason string) Message

func BuildRunCanceledMessage

func BuildRunCanceledMessage(runID int) Message

func BuildRunCompletedMessage

func BuildRunCompletedMessage(runID int) Message

func BuildRunFailedMessage

func BuildRunFailedMessage(runID int, detail string) Message

type Notifier

type Notifier interface {
	Notify(msg Message)
	Close(ctx context.Context) error
}

func NewDesktopNotifier

func NewDesktopNotifier(cfg DesktopConfig) Notifier

func NewNoopNotifier

func NewNoopNotifier() Notifier

Jump to

Keyboard shortcuts

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