[workflow] PR cant be merged until CI workflow is finished without error. #26

Closed
opened 2026-09-19 20:17:33 +02:00 by kamilkrzywda · 1 comment
Owner

But can be set to automerge.
Edit gitea workflow.

But can be set to automerge. Edit gitea workflow.
Author
Owner

Done — two parts:

  1. Branch protection (via Gitea API): master now requires the status check CI / build + unit + e2e (pull request) to be successful before a PR can be merged. Verified with a throwaway PR (#29, closed unmerged): a normal merge attempt returns 405 "Not all required status checks successful".
  2. Auto-merge: the merge API supports merge_when_checks_succeed — queueing a PR (POST /pulls/{n}/merge with body {"do":"merge","merge_style":"merge","merge_when_checks_succeed":true}) makes Gitea merge it automatically once CI goes green. Verified live: this exact flow merged the documentation PR (#30, v0.19.1).

AGENTS.md change-process item 5 now documents both (v0.19.1), so future work queues auto-merge instead of merging manually.

Done — two parts: 1. **Branch protection** (via Gitea API): `master` now requires the status check **CI / build + unit + e2e (pull request)** to be successful before a PR can be merged. Verified with a throwaway PR (#29, closed unmerged): a normal merge attempt returns 405 "Not all required status checks successful". 2. **Auto-merge**: the merge API supports `merge_when_checks_succeed` — queueing a PR (`POST /pulls/{n}/merge` with body `{"do":"merge","merge_style":"merge","merge_when_checks_succeed":true}`) makes Gitea merge it automatically once CI goes green. Verified live: this exact flow merged the documentation PR (#30, v0.19.1). `AGENTS.md` change-process item 5 now documents both (v0.19.1), so future work queues auto-merge instead of merging manually.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: OpenCode/Flight-Ops#26