Documentation
¶
Index ¶
- Constants
- Variables
- func AddMultipleWorkflowsWithRepo(workflows []string, number int, verbose bool, engineOverride string, ...) error
- func AddMultipleWorkflowsWithRepoAndPR(workflows []string, number int, verbose bool, engineOverride string, ...) error
- func AddWorkflowWithRepo(workflow string, number int, verbose bool, engineOverride string, ...) error
- func AddWorkflowWithRepoAndPR(workflow string, number int, verbose bool, engineOverride string, ...) error
- func AddWorkflowWithTracking(workflow string, number int, verbose bool, engineOverride string, name string, ...) error
- func AddWorkflows(workflows []string, number int, verbose bool, engineOverride string, ...) error
- func CompileWorkflows(markdownFile string, verbose bool, engineOverride string, validate bool, ...) error
- func DisableWorkflows(pattern string) error
- func DownloadWorkflowLogs(workflowName string, count int, startDate, endDate, outputDir, engine string, ...) error
- func EnableWorkflows(pattern string) error
- func GetVersion() string
- func InspectWorkflowMCP(workflowFile string, serverFilter string, toolFilter string, verbose bool) error
- func InstallPackage(repoSpec string, local bool, verbose bool) error
- func IsRunnable(markdownPath string) (bool, error)
- func ListPackages(local bool, verbose bool) error
- func ListWorkflows(verbose bool) error
- func NewLogsCommand() *cobra.Command
- func NewMCPInspectCommand() *cobra.Command
- func NewWorkflow(workflowName string, verbose bool, force bool) error
- func RemoveWorkflows(pattern string, keepOrphans bool) error
- func RunWorkflowOnGitHub(workflowIdOrName string, verbose bool) error
- func RunWorkflowsOnGitHub(workflowNames []string, repeatSeconds int, verbose bool) error
- func SetVersionInfo(v string)
- func StatusWorkflows(pattern string, verbose bool) error
- func UninstallPackage(repoSpec string, local bool, verbose bool) error
- type DownloadResult
- type FileTracker
- func (ft *FileTracker) GetAllFiles() []string
- func (ft *FileTracker) RollbackAllFiles(verbose bool) error
- func (ft *FileTracker) RollbackCreatedFiles(verbose bool) error
- func (ft *FileTracker) RollbackModifiedFiles(verbose bool) error
- func (ft *FileTracker) StageAllFiles(verbose bool) error
- func (ft *FileTracker) TrackCreated(filePath string)
- func (ft *FileTracker) TrackModified(filePath string)
- type GitHubWorkflow
- type IncludeDependency
- type LogMetrics
- type Package
- type WorkflowMatch
- type WorkflowRun
- type WorkflowSourceInfo
Constants ¶
const ( // MaxIterations limits how many batches we fetch to prevent infinite loops MaxIterations = 20 // BatchSize is the number of runs to fetch in each iteration BatchSize = 100 // BatchSizeForAllWorkflows is the larger batch size when searching for agentic workflows // There can be a really large number of workflow runs in a repository, so // we are generous in the batch size when used without qualification. BatchSizeForAllWorkflows = 250 // MaxConcurrentDownloads limits the number of parallel artifact downloads MaxConcurrentDownloads = 10 )
Constants for the iterative algorithm
Variables ¶
var ErrNoArtifacts = errors.New("no artifacts found for this run")
ErrNoArtifacts indicates that a workflow run has no artifacts
Functions ¶
func AddMultipleWorkflowsWithRepo ¶ added in v0.2.7
func AddMultipleWorkflowsWithRepo(workflows []string, number int, verbose bool, engineOverride string, repoSpec string, name string, force bool) error
AddMultipleWorkflowsWithRepo adds multiple workflows from components to .github/workflows with optional repository installation Deprecated: Use AddWorkflows instead
func AddMultipleWorkflowsWithRepoAndPR ¶ added in v0.2.7
func AddMultipleWorkflowsWithRepoAndPR(workflows []string, number int, verbose bool, engineOverride string, repoSpec string, name string, force bool) error
AddMultipleWorkflowsWithRepoAndPR adds multiple workflows from components to .github/workflows with optional repository installation and creates a PR Deprecated: Use AddWorkflows instead
func AddWorkflowWithRepo ¶
func AddWorkflowWithRepo(workflow string, number int, verbose bool, engineOverride string, repoSpec string, name string, force bool) error
AddWorkflowWithRepo adds a workflow from components to .github/workflows with optional repository installation Deprecated: Use AddWorkflows instead
func AddWorkflowWithRepoAndPR ¶
func AddWorkflowWithRepoAndPR(workflow string, number int, verbose bool, engineOverride string, repoSpec string, name string, force bool) error
AddWorkflowWithRepoAndPR adds a workflow from components to .github/workflows with optional repository installation and creates a PR Deprecated: Use AddWorkflows instead
func AddWorkflowWithTracking ¶ added in v0.0.22
func AddWorkflowWithTracking(workflow string, number int, verbose bool, engineOverride string, name string, force bool, tracker *FileTracker) error
AddWorkflowWithTracking adds a workflow from components to .github/workflows with file tracking
func AddWorkflows ¶ added in v0.2.7
func AddWorkflows(workflows []string, number int, verbose bool, engineOverride string, repoSpec string, name string, force bool, createPR bool) error
AddWorkflows adds one or more workflows from components to .github/workflows with optional repository installation and PR creation
func CompileWorkflows ¶
func CompileWorkflows(markdownFile string, verbose bool, engineOverride string, validate bool, watch bool, writeInstructions bool) error
CompileWorkflows compiles markdown files into GitHub Actions workflow files
func DisableWorkflows ¶
DisableWorkflows disables workflows matching a pattern
func DownloadWorkflowLogs ¶
func DownloadWorkflowLogs(workflowName string, count int, startDate, endDate, outputDir, engine string, verbose bool) error
DownloadWorkflowLogs downloads and analyzes workflow logs with metrics
func EnableWorkflows ¶
EnableWorkflows enables workflows matching a pattern
func InspectWorkflowMCP ¶
func InspectWorkflowMCP(workflowFile string, serverFilter string, toolFilter string, verbose bool) error
InspectWorkflowMCP inspects MCP servers used by a workflow and lists available tools, resources, and roots
func InstallPackage ¶
InstallPackage installs agentic workflows from a GitHub repository
func IsRunnable ¶
IsRunnable checks if a workflow can be run (has schedule or workflow_dispatch trigger)
func ListPackages ¶
ListPackages lists all installed packages
func ListWorkflows ¶
ListWorkflows lists available workflow components
func NewMCPInspectCommand ¶ added in v0.2.0
NewMCPInspectCommand creates the mcp-inspect command
func NewWorkflow ¶
NewWorkflow creates a new workflow markdown file with template content
func RemoveWorkflows ¶
RemoveWorkflows removes workflows matching a pattern
func RunWorkflowOnGitHub ¶
RunWorkflowOnGitHub runs an agentic workflow on GitHub Actions
func RunWorkflowsOnGitHub ¶ added in v0.2.4
RunWorkflowsOnGitHub runs multiple agentic workflows on GitHub Actions, optionally repeating at intervals
func SetVersionInfo ¶
func SetVersionInfo(v string)
SetVersionInfo sets the version information for the CLI
func StatusWorkflows ¶
Types ¶
type DownloadResult ¶ added in v0.0.25
type DownloadResult struct {
Run WorkflowRun
Metrics LogMetrics
Error error
Skipped bool
LogsPath string
}
DownloadResult represents the result of downloading artifacts for a single run
type FileTracker ¶ added in v0.0.22
type FileTracker struct {
CreatedFiles []string
ModifiedFiles []string
OriginalContent map[string][]byte // Store original content for rollback
// contains filtered or unexported fields
}
FileTracker keeps track of files created or modified during workflow operations to enable proper staging and rollback functionality
func NewFileTracker ¶ added in v0.0.22
func NewFileTracker() (*FileTracker, error)
NewFileTracker creates a new file tracker
func (*FileTracker) GetAllFiles ¶ added in v0.0.22
func (ft *FileTracker) GetAllFiles() []string
GetAllFiles returns all tracked files (created and modified)
func (*FileTracker) RollbackAllFiles ¶ added in v0.0.22
func (ft *FileTracker) RollbackAllFiles(verbose bool) error
RollbackAllFiles rolls back both created and modified files
func (*FileTracker) RollbackCreatedFiles ¶ added in v0.0.22
func (ft *FileTracker) RollbackCreatedFiles(verbose bool) error
RollbackCreatedFiles deletes all files that were created during the operation
func (*FileTracker) RollbackModifiedFiles ¶ added in v0.0.22
func (ft *FileTracker) RollbackModifiedFiles(verbose bool) error
RollbackModifiedFiles restores all modified files to their original state
func (*FileTracker) StageAllFiles ¶ added in v0.0.22
func (ft *FileTracker) StageAllFiles(verbose bool) error
StageAllFiles stages all tracked files using git add
func (*FileTracker) TrackCreated ¶ added in v0.0.22
func (ft *FileTracker) TrackCreated(filePath string)
TrackCreated adds a file to the created files list
func (*FileTracker) TrackModified ¶ added in v0.0.22
func (ft *FileTracker) TrackModified(filePath string)
TrackModified adds a file to the modified files list and stores its original content
type GitHubWorkflow ¶
type GitHubWorkflow struct {
ID int64 `json:"id"`
Name string `json:"name"`
Path string `json:"path"`
State string `json:"state"`
}
GitHubWorkflow represents a GitHub Actions workflow from the API
type IncludeDependency ¶
type IncludeDependency struct {
SourcePath string // Path in the source (local)
TargetPath string // Relative path where it should be copied in .github/workflows
IsOptional bool // Whether this is an optional include (@include?)
}
IncludeDependency represents a file dependency from @include directives
type LogMetrics ¶
type LogMetrics = workflow.LogMetrics
LogMetrics represents extracted metrics from log files This is now an alias to the shared type in workflow package
type WorkflowMatch ¶
WorkflowMatch represents a workflow match in package search
type WorkflowRun ¶
type WorkflowRun struct {
DatabaseID int64 `json:"databaseId"`
Number int `json:"number"`
URL string `json:"url"`
Status string `json:"status"`
Conclusion string `json:"conclusion"`
WorkflowName string `json:"workflowName"`
CreatedAt time.Time `json:"createdAt"`
StartedAt time.Time `json:"startedAt"`
UpdatedAt time.Time `json:"updatedAt"`
Event string `json:"event"`
HeadBranch string `json:"headBranch"`
HeadSha string `json:"headSha"`
DisplayTitle string `json:"displayTitle"`
Duration time.Duration
TokenUsage int
EstimatedCost float64
LogsPath string
}
WorkflowRun represents a GitHub Actions workflow run with metrics