devantler-tech / devantler-tech/ksail
fix(release): cask PRs open with a non-Conventional title the tap ruleset rejects
- Dominant language
- Go
- Stars
- 165
- Forks
- 12
- Avg merge
- 5h 51m
- Merged PRs (30d)
- 347
Description
> 🤖 Generated by the Agentic Engineer
## Evidence
Every GoReleaser cask PR this repository opens on the tap has to be **renamed by hand before it can merge**, once per release, for both `ksail` and `ksail-desktop`.
`devantler-tech/homebrew-tap` enforces a `commit_message_pattern` ruleset on `main`:
```
^(build|chore|ci|docs|feat|fix|perf|refactor|revert|style|test){1}(\([\w\-\.]+\))?(!)?:
```
The tap squash-merges on the PR title, so the title must match. GoReleaser's default commit message does not:
| Tap PR | Title as opened | Renames |
|---|---|---|
| #1591 `ksail` v7.183.3 | `Brew cask update for ksail version v7.183.3` | 1 |
| #1590 `ksail-desktop` v7.183.3 | `Brew cask update for ksail-desktop version v7.183.3` | 1 |
| #1589 `ksail` v7.183.2 | `Brew cask update for ksail version v7.183.2` | 1 |
| #1588 `ksail-desktop` v7.183.2 | `Brew cask update for ksail-desktop version v7.183.2` | 1 |
| #1587 `ksail` v7.183.0 | `Brew cask update for ksail version v7.183.0` | 2 |
| #1582 `world-at-ruin` v0.100.0 | `chore(cask): update world-at-ruin to v0.100.0` | **0** |
`world-at-ruin` is the control, and it is the useful one: its cask PR needs no rename because it is produced by a CD workflow rather than by GoReleaser's own `pull_request` support, so its title is Conventional from birth.
## Root cause
`.goreleaser.yaml`'s `homebrew_casks` entry sets `commit_author` but **not `commit_msg_template`**, so GoReleaser falls back to its default `Brew cask update for {{ .ProjectName }} version {{ .Tag }}` — which has no Conventional type prefix. That message becomes the PR title, and the tap's ruleset rejects it.
## Why this is worth fixing rather than absorbing
The failure is **silent and misleading**. The PR looks completely healthy — all checks green, no review threads, `mergeStateStatus` eventually `CLEAN` — and the merge attempt fails with:
```
Pull request ... is not mergeable: the base branch policy prohibits the merge.
```
That message names no rule and points at nothing. It reads exactly like a stale `mergeStateStatus`, so the natural next move is to re-read and retry, which fails again. Diagnosing it means enumerating the branch rules and comparing the title against a regex — several minutes of work, repeated every release, by whoever happens to pick the PR up. It also delays every release reaching Homebrew users by however long it takes someone to notice.
## Expected behaviour
A cask PR opens with a title that already satisfies the tap's ruleset, so the trusted programmed release path (check-gated auto-merge, no review or promotion step, per #6095) completes without a human or agent editing the title.
## Acceptance criteria
- [ ] `homebrew_casks[].repository.pull_request` (or the enclosing entry) sets a `commit_msg_template` producing a Conventional title — matching the shape already in use, `chore(cask): update to `.
- [ ] Verify the regex above actually matches the rendered template output, rather than assuming it does.
- [ ] Confirm on the next real release that the tap PR opens with the Conventional title and needs **no** rename — this is the acceptance signal, and it can only be observed at release time.
- [ ] Applies to both casks produced here (`ksail` and `ksail-desktop`); confirm both.
**Size:** small — a template string plus one release-time confirmation.
Contributor guide
Research direction
Start in .goreleaser.yaml at the homebrew_casks repository.pull_request configuration and inspect how its commit message is rendered for ksail and ksail-desktop. Check the rendered title against the tap regex, then verify on the next release that both cask PRs open with Conventional titles and require no rename.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, go, yaml
- Domain
- ci-cd, release
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 78/100