protect

Verify and enforce GitHub branch protection settings against a specified policy.

2|Updated May 19, 2026
One-click install
npx skills add https://github.com/element22llc/e22-plugins --skill protect-element22llc
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: protect
Source: https://github.com/element22llc/e22-plugins/tree/main/plugins/steer/skills/protect
Command: npx skills add https://github.com/element22llc/e22-plugins --skill protect-element22llc

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires gh, and includes scripts (resource) components.

What problem does it solve?

This Skill ensures that GitHub branch protection is properly configured and enforceable, preventing unauthorized direct pushes to critical branches.

Core Features & Use Cases

  • Branch Protection Verification: Checks if the GitHub branch protection settings match the required policy.
  • Policy Compliance: Verifies the presence and correctness of branch protection, required status checks, and other security measures.
  • Automated Application: Applies missing branch protection settings upon confirmation, enhancing code safety and maintainability.
  • Use Case: For organizations that require strict control over their main branch, this Skill can be used to enforce pull request requirements and code reviews.

Quick Start

Verify or apply branch protection settings for the 'main' branch using the 'protect' skill.

Frequently Asked Questions about protect

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I verify GitHub branch protection settings match my security policy?

To verify GitHub branch protection settings, this Skill compares your current repository configuration against a specified security policy and reports any missing required status checks or security measures. It ensures branch protection is properly configured and enforceable.

Can I enforce required status checks and pull request reviews on the main branch?

Yes, you can enforce required status checks and pull request reviews on the main branch. The Skill verifies branch protection rules and applies missing security settings upon explicit user confirmation to prevent unauthorized direct pushes to critical branches.

Do I need the gh CLI to apply branch protection rules?

Yes, you need the gh CLI installed and authenticated. The Skill requires gh for GitHub API authentication and API calls to verify existing branch protection settings and apply missing configurations to your repository.

What's the best way to prevent unauthorized direct pushes to critical GitHub branches?

The best way to prevent unauthorized direct pushes is to enforce branch protection policies. This Skill checks your repository against required security measures and applies missing branch protection settings with explicit user confirmation to enhance code safety.

Does applying missing branch protection settings require manual confirmation?

Yes, applying missing branch protection settings requires explicit user confirmation. The Skill first verifies current settings against your policy, then prompts for confirmation before automatically applying any missing security configurations to the branch.