Skip to content

Commit 58c28ca

Browse files
authored
Document custom merge queue systems (#198)
1 parent 81a4a09 commit 58c28ca

1 file changed

Lines changed: 19 additions & 4 deletions

File tree

docs/learn/integrations/github.mdx

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,11 @@ Argos needs the following permissions to operate:
5858

5959
We take your security and privacy seriously. If you have any concerns or questions, please [contact us](https://argos-ci.com/contact).
6060

61-
## GitHub Merge Queue support
61+
## Merge Queue support
6262

63-
Argos supports GitHub Merge Queue when you use the full-access Argos GitHub App. Merge Queue relies on Argos reading commit history to compute merge bases and publish required checks, so the restricted “GitHub without content access” integration does not support it. When Argos runs inside the merge queue, it compares your queued change against the previously approved commit on the target branch to ensure only clean visual changes are merged.
63+
When Argos runs inside the merge queue, it compares the queued changes against the merge base of all pull requests in the queue, ensuring that visual tests reflect the final merged state. This is supported out of the box with [GitHub's native Merge Queue](https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/managing-a-merge-queue), and can be configured for custom merge queue systems as well.
6464

65-
### GitHub Actions setup for Merge Queue
65+
### GitHub Actions setup for GitHub Merge Queue
6666

6767
Listen to both `pull_request` and `merge_group` events so Argos uploads run for PR reviews and for queued merges:
6868

@@ -85,9 +85,24 @@ jobs:
8585
ARGOS_TOKEN: ${{ secrets.ARGOS_TOKEN }} # Argos token stored in GitHub Secrets
8686
```
8787
88+
### Custom merge queue systems
89+
90+
When you are using a merge queue system other than GitHub’s built-in Merge Queue (like [Mergify](https://mergify.com/)), you can set `ARGOS_MERGE_QUEUE_PRS` to the comma-separated pull request numbers included in the queued build. This tells Argos to treat the upload as a merge queue build and use the right baseline for visual comparisons.
91+
92+
```yml
93+
steps:
94+
- name: Upload screenshots to Argos
95+
env:
96+
ARGOS_TOKEN: ${{ secrets.ARGOS_TOKEN }}
97+
ARGOS_MERGE_QUEUE_PRS: "101,102"
98+
run: npm exec -- argos upload ./screenshots
99+
```
100+
101+
Use the pull request numbers included in the merge queue batch. Passing `ARGOS_MERGE_QUEUE_PRS` tells Argos to treat the upload as a merge queue build.
102+
88103
## GitHub Integration without Content Permission
89104

90-
If you prefer to use Argos without granting full content access to your repositories, you can integrate via a more restricted setup. This mode does not support Merge Queue because Argos cannot read commit history.
105+
If you prefer to use Argos without granting full content access to your repositories, you can integrate via a more restricted setup.
91106

92107
### Setting Up Argos with Limited GitHub Access
93108

0 commit comments

Comments
 (0)