~sircmpwn/sr.ht-docs

784bf1c5815d72e749908882aea27441303e75f7 — Drew DeVault 2 years ago 03440ab
Add dispatch.sr.ht docs
2 files changed, 47 insertions(+), 0 deletions(-)

A dispatch.sr.ht/github.md
A dispatch.sr.ht/index.md
A dispatch.sr.ht/github.md => dispatch.sr.ht/github.md +30 -0
@@ 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)

A dispatch.sr.ht/index.md => dispatch.sr.ht/index.md +17 -0
@@ 0,0 1,17 @@
[dispatch.sr.ht](https://dispatch.sr.ht) is a service on sr.ht that can be used
to automate tasks in response to various events. It's often used, for example,
to automate the submission of builds.sr.ht jobs in response to, for example, git
commits. It's designed to support many other automations as well.

# Dashboard

On the dashboard we see a searchable list of your configured tasks. Clicking
each task will take you to a settings page. On the left is the "Configure new
task" button, used for that purpose.

# Configuring new tasks

The list of available tasks is shown on the [task configuration
page](https://dispatch.sr.ht/configure). Select a task to configure it, and you
will be taken to a task-specific configuration page. Documentation for each task
is available on these pages.