.stackat.yml / option
auto_merge
On this page
Lets low-risk pull requests merge themselves. With auto_merge: true, Stackat turns on GitHub's auto-merge for each low-risk pull request it opens, and GitHub merges it once the branch's required checks pass.
What it does
true: when Stackat opens a low-risk pull request, it turns on GitHub's auto-merge for it and says so in a comment on the pull request. GitHub merges it once everything the branch requires has passed: status checks, reviews, any rule you set. Nothing else changes: issues, drafts and every other pull request stay as they are.false, or not set: every pull request waits for a person.
Low risk means all of these:
- The issue says safe to upgrade: nothing in the release notes touches your files, and Stackat rates the upgrade at most 4 out of 10.
- No new major version between your version and the target.
- A ready pull request, not a draft.
Everything else (edits needed, review before upgrading, a migration) waits for a person, whatever auto_merge says.
Where the repository allows it
Stackat uses GitHub's own auto-merge, so the repository's rules decide:
- Settings, General, Allow auto-merge must be on.
- The target branch must require status checks (a branch protection rule or a ruleset). GitHub refuses auto-merge on a branch that requires nothing, because the pull request would merge at once. So a pull request never merges before your checks have passed.
Where either is missing, the pull request gets a comment saying which, and waits for a person. Stackat uses the repository's allowed merge method: squash when allowed, otherwise a merge commit, otherwise rebase.
Auto-merge needs pull requests: the Stackpaw app, on the trial or Pro, and auto_pr: true or a /stackpaw pr reply. With environments, each environment's pull request merges itself the same way, and the next environment's still opens only after the soak time.
Type and values
| Type | Boolean |
| Allowed | true or false |
| Default | Off: a person merges every pull request |
Organisation and repository
Set in the organisation's file, it applies to every repository. A repository's own auto_merge replaces it, in either direction.
Problems you may see
.stackat.yml: auto_merge must be true or falseAnything but true or false is that problem, and the setting is ignored.
On the pull request, one of these comments when GitHub would not turn auto-merge on:
Not set to merge itself: the repository does not allow auto-merge (Settings, General, Allow auto-merge).
Not set to merge itself: the branch requires no status checks, so GitHub would merge it at once.Examples
Low-risk upgrades merge themselves everywhere
auto_pr: true
auto_merge: trueExcept one repository
auto_merge: false