~sircmpwn/sr.ht-docs

ref: 9412f07b6e753fbb32ae807fa50edc6bcd6b47d4 sr.ht-docs/dispatch.sr.ht/github.md -rw-r--r-- 1.1 KiB
9412f07bDrew DeVault Add dispatch.sr.ht to index.md 2 years ago

dispatch.sr.ht supports various integrations with GitHub. Some tips are provided here.

#Configuring branch protection rules on GitHub

If you choose the "auto-merge" setting, builds.sr.ht will attempt to merge the pull request once the build completes successfully. You will likely want to add branch protection rules on GitHub to prevent this from happening before the pull request is reviewed.

To edit your branch protection rules, start by visiting "Branches" in your repository's settings.

Screenshot of the "branches" page

Select "Add rule".

Screenshot of "add rule"

Specify the branches you want the rule to apply to (e.g. "master") and configure the criteria which must be met for the pull request to be mergeable. For example, to require the code to be reviewed before merge:

Important: if your account is an administrator on this GitHub repository, attempts to merge will succeed even if the branch protection rules are unmet. You must enable the "Include administrators" option to prevent this.