HackyJS CoursesMerge Gates: Hardening a GitHub Org for AI-Written Code

// module 03 · Enforcement developers can't turn off

Rulesets: repo and org, free and paid

Rulesets are how GitHub enforces merge rules today. This lesson compares them with classic branch protection, shows how several rulesets stack on one branch, and walks through targets, bypass modes and enforcement states with real results from a Free org. It ends with the org ruleset you would use on Team or Enterprise, targeted by the `tier` property, and why on Free a repo admin can still delete the rules.

  • Lesson 7 of 34

Learning Objectives

  • Explain what rulesets add over classic branch protection rules
  • Predict the effective rules when two rulesets target the same branch
  • Choose a target (branch, tag, push) and say which ones a Free public repo accepts
  • Pick a bypass mode (always, pull requests only, exempt) and say what each one allows
  • Write an org ruleset that targets repos by a custom property, and validate it without a paid plan
  • Name who can edit or delete a repo ruleset, and why that needs a drift check

This lesson is for enrolled learners

Log in, then enroll to read the full lesson, run its lab and take the quiz.