How do you avoid workflow sprawl and duplicated YAML in large GitHub repos?
BeginnerProductionGitHub Actions and GitLab CI in Production
Answer
Extract repeated step sequences into composite actions and whole pipelines into reusable workflows, use matrices instead of copy-paste jobs, set defaults.run once, and keep YAML anchors in mind: GitHub Actions now supports YAML anchors in workflow files. Name workflows clearly, keep one purpose per workflow (ci, release, nightly, security), and delete workflows no one uses.
More on GitHub Actions and GitLab CI in Production
How do you organise reusable workflows for an organisation on GitHub?IntermediateHow do you reduce GitHub Actions minutes cost on private repos?IntermediateHow do you secure self-hosted runners?AdvancedHow do you design the GitHub Actions OIDC trust policy for AWS safely?AdvancedHow do you handle approvals and deployments across environments in GitHub Actions?IntermediateHow do you handle required checks when workflows use path filters or matrices?Advanced