MCPcopy Create free account
hub / github.com/github/gh-aw / runDeployAddPass

Function runDeployAddPass

pkg/cli/deploy_command.go:227–244  ·  view source on GitHub ↗
(ctx context.Context, resolvedWorkflows []string, addOpts AddOptions)

Source from the content-addressed store, hash-verified

225}
226
227func runDeployAddPass(ctx context.Context, resolvedWorkflows []string, addOpts AddOptions) error {
228 workflowsToAdd, skippedWorkflows, err := excludeExistingSourcedWorkflows(resolvedWorkflows, addOpts)
229 if err != nil {
230 return fmt.Errorf("failed to inspect existing workflows: %w", err)
231 }
232 if len(skippedWorkflows) > 0 {
233 deployLog.Printf("Skipping add for existing sourced workflows (already handled by update): %s", strings.Join(skippedWorkflows, ", "))
234 }
235 if len(workflowsToAdd) == 0 {
236 deployLog.Print("No new workflows to add after update pass")
237 return nil
238 }
239
240 if _, err := AddWorkflows(ctx, workflowsToAdd, addOpts); err != nil {
241 return fmt.Errorf("failed to add workflows: %w", err)
242 }
243 return nil
244}
245
246func runDeployCompilePass(ctx context.Context, addOpts AddOptions) error {
247 compileConfig := CompileConfig{

Callers 1

runDeployFunction · 0.85

Calls 5

AddWorkflowsFunction · 0.85
PrintMethod · 0.80
ErrorfMethod · 0.45
PrintfMethod · 0.45

Tested by

no test coverage detected