Merge your first pull request

The last steps of the installation, protect the target branch, check that your CI runs on the tests of the queue, then submit a first pull request and follow it to the merge.

CIHub runs and the App is installed on your repositories. You do not create a queue: the first /cihub merge on a pull request of the default branch creates it, with the default settings.

Protect the target branch

Two rulesets on the target branch make every merge go through the queue: one that restricts the updates, with the App in its bypass list in the mode Exempt, and one that holds the rules of a pull request. Turn off "Require branches to be up to date before merging". Protect the target branch gives each click.

Merge button, git pusha person, a botCIHubafter a test that passedRestrict updatesExemptmainthe target branchstays green
The ruleset that restricts updates lets only the App of CIHub, in the mode Exempt, write the target branch.

Check that your CI runs on the tests

By default, each test of the queue opens a draft pull request: a workflow on pull_request runs on it without a change, if it does not skip draft pull requests. The test waits for the required checks of the rules of the branch. Run your CI on the tests of the queue covers GitHub Actions and the other CIs.

Submit a pull request

Choose a pull request of the default branch that is approved and whose checks pass, and comment:

/cihub merge

CIHub adds a 👍 reaction, then a comment that it keeps up to date, and the status CIHub Merge Queue (main):

acme-cihubbotcommented

🧪 Testing · position 2 in the queue for main

Tested on top of #118, #119 in #130.

Open in CIHub

▸ History (3)

/cihub restart to test again · /cihub cancel to leave the queue

CIHub Merge Queue (main)Testing, position 2Details
CIHub Conditions (main)Ready for the queue
The comment of CIHub, edited at each change, and its two statuses in the checks of the pull request.

The pull request merges when its test passes. If it waits, the comment says why: The life of a pull request in the queue.

Follow the queue

The link Open in CIHub of the comment opens the pull request in the dashboard, with its queue. From a terminal, the command line shows the same:

cihub auth login --hostname cihub.example.com   # approve the code in the dashboard
cihub queue status

Install the command line first.

In a CI, set CIHUB_HOST and CIHUB_TOKEN, with an API token of the organization.

Next

On this page

For agentsThis page as Markdown:/docs/install/first-pull-request.md