A GitHub Action that powers the CODEOWNERS.
Note: GitHub's official "Required review by specific teams" (Rulesets) feature is now available: https://github.blog/changelog/2025-11-03-required-review-by-specific-teams-now-available-in-rulesets/.
We recommend using the native GitHub feature when possible. This Action will be kept in a minimal form for compatibility and special cases, but the official solution should be preferred for new integrations.
- name: Verify CODEOWNERs and Changed Files
uses: endersonmenezes/codeowners-superpowers@main
with:
super_power: "require-all-codeowners"
gh-token: ${{ steps.app-token.outputs.token }}
pr_number: ${{ github.event.number }}
owner_and_repository: ${{ github.repository }}- require-all-codeowners
This Superpower will check if all codeowners necessary have been approved in the PR.
Based on: this discussion
- Create a GitHub App inside your organization or repository.
- That GitHub App needs to have the following permissions:
- Read access to files located at
.github/CODEOWNERS - Read access to code, members, metadata, and pull requests
- Read access to files located at
- Use the actions/create-github-app-token@v2 before use the GATE with Superpowers.