Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetVersion ¶
func SetVersion(v string)
Types ¶
type RunOptions ¶ added in v0.0.10
type RunOptions struct {
DryRun bool
Watch bool
NoTUI bool
Author string
TrustedAuthors string
MergeAuto bool
Org string
ReposFile string
Grouping string
SecurityPatterns string
Cols []pr.TableColumn
OnComplete func(*pr.PRStatus)
}
RunOptions holds the configuration shared between the run and sweep commands.
type SweepPREntry ¶ added in v0.0.23
type SweepPREntry struct {
Owner string `json:"owner"`
Repo string `json:"repo"`
Number int `json:"number"`
Title string `json:"title"`
URL string `json:"url"`
Status string `json:"status"`
Detail string `json:"detail,omitempty"`
CreatedAt string `json:"created_at,omitempty"`
AgeDays int `json:"age_days,omitempty"`
// Rescue describes the most recent prior automated rescue attempt
// found on the PR (an ai-rescue marker comment), if any. Consumers
// dispatching rescue agents should skip entries with a non-stale
// failed rescue and escalate them to a human instead.
Rescue *SweepRescueInfo `json:"rescue,omitempty"`
}
SweepPREntry represents a single PR in the sweep results.
type SweepRescueInfo ¶ added in v0.0.49
type SweepRescueInfo struct {
Tool string `json:"tool,omitempty"`
Outcome string `json:"outcome"`
Reason string `json:"reason,omitempty"`
At string `json:"at,omitempty"`
// Stale is true when the PR head moved since the rescue attempt --
// the attempt no longer describes the current code and the PR is
// fair game for another rescue.
Stale bool `json:"stale"`
}
SweepRescueInfo is the JSON projection of a pr.RescueMarker.
type SweepResult ¶ added in v0.0.23
type SweepResult struct {
Summary SweepSummary `json:"summary"`
Merged []SweepPREntry `json:"merged,omitempty"`
SecurityFailures []SweepPREntry `json:"security_failures,omitempty"`
ActionRequired []SweepPREntry `json:"action_required,omitempty"`
// CIUnavailable lists PRs whose CI could not run because a GitHub Actions
// budget / spending-limit block prevented every job from starting. These
// are NOT failures: the remedy is to raise or await the Actions budget,
// so they are reported separately and excluded from action_required.
Skipped []SweepPREntry `json:"skipped,omitempty"`
}
SweepResult is the structured JSON output returned by the sweep MCP tool.
type SweepSummary ¶ added in v0.0.23
type SweepSummary struct {
Total int `json:"total"`
Merged int `json:"merged"`
Failed int `json:"failed"`
SecurityFailures int `json:"security_failures"`
// CIUnavailable counts PRs whose CI could not run because of a GitHub
// Actions budget block. It is disjoint from Failed and SecurityFailures.
Skipped int `json:"skipped"`
}
SweepSummary contains aggregate counts from the sweep.
Failed and SecurityFailures are disjoint: Failed counts only the non-security failure entries, so consumers can use Failed + SecurityFailures to get the total number of action-required PRs without double-counting.
Click to show internal directories.
Click to hide internal directories.