makeopensource / Classic-RPG

A classic role-playing game with an engine.
GNU General Public License v3.0
7 stars 19 forks source link

Set up push restrictions so no more pushing to upstream #67

Closed russella26 closed 2 years ago

WeirdAlex03 commented 2 years ago

Settings > Branches > Add rule (next to "Branch protection rules" heading) > Require a pull request before merging (and anything else we want)

More info: https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/managing-a-branch-protection-rule

Full list of rules available (most of these have sub-options exposed when they're selected, you can see these if you make your own fork):

Protect matching branches

Require a pull request before merging When enabled, all commits must be made to a non-protected branch and submitted via a pull request before they can be merged into a branch that matches this rule.

Require status checks to pass before merging Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a branch that matches this rule after status checks have passed.

Require conversation resolution before merging When enabled, all conversations on code must be resolved before a pull request can be merged into a branch that matches this rule. Learn more.

Require signed commits Commits pushed to matching branches must have verified signatures.

Require linear history Prevent merge commits from being pushed to matching branches.

Require deployments to succeed before merging Choose which environments must be successfully deployed to before branches can be merged into a branch that matches this rule.

Include administrators Enforce all configured restrictions above for administrators.

Rules applied to everyone including administrators

Allow force pushes Permit force pushes for all users with push access.

Allow deletions Allow users with push access to delete matching branches.

russella26 commented 2 years ago

done! branch protection rule made