aboutsummaryrefslogtreecommitdiffstats
path: root/dispatch.sr.ht/github.md
diff options
context:
space:
mode:
Diffstat (limited to 'dispatch.sr.ht/github.md')
-rw-r--r--dispatch.sr.ht/github.md30
1 files changed, 30 insertions, 0 deletions
diff --git a/dispatch.sr.ht/github.md b/dispatch.sr.ht/github.md
new file mode 100644
index 0000000..be41ad2
--- /dev/null
+++ b/dispatch.sr.ht/github.md
@@ -0,0 +1,30 @@
+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](https://sr.ht/465d.png)
+
+Select "Add rule".
+
+![Screenshot of "add rule"](https://sr.ht/rtPV.png)
+
+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:
+
+![](https://sr.ht/UeBt.png)
+
+**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.
+
+![](https://sr.ht/7VYq.png)