Skip to content

[deep-report] Replace copilot_setup.go's duplicate GHA workflow model with pkg/workflow types #54529

Description

@github-actions

Description

pkg/cli/copilot_setup.go:356,365,372 hand-rolls a second, smaller GitHub Actions workflow-file object model (CopilotWorkflowStep{Name, Uses, Run, With, Env}, WorkflowJob{RunsOn, Permissions, Steps}, Workflow{Name, On, Jobs}) purely to scaffold copilot-setup-steps.yml, instead of reusing pkg/workflow's existing WorkflowStep/Job types (pkg/workflow/step_types.go:17). Verified live at all cited locations — this is a second, independently-maintained "what does a GHA step/job look like" model in the same codebase.

Expected Impact

One source of truth for the GitHub Actions step/job shape instead of two, removing drift risk between pkg/workflow's primary model and pkg/cli's scaffold-only copy.

Suggested Agent

Copilot coding agent — check whether workflow.WorkflowStep/Job can serialize to the subset copilot-setup-steps.yml needs, replace CopilotWorkflowStep/WorkflowJob/Workflow with the existing types (or a thin shared package), update scaffold-generation call sites, run tests.

Estimated Effort

Medium (2-4 hours)

Data Source

DeepReport analysis, 2026-08-21 cycle, sourced from discussion #54506 (Typist - Go Type Consistency Analysis), Cluster 4. No existing open issue found covering this specific duplication.

Generated by 🔬 Deep Report · agent · 186.6 AIC · ⌖ 14.7 AIC · ⊞ 11.9K ·

  • expires on Aug 23, 2026, 4:35 AM UTC-08:00

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions