Add an auto-merge indicator to the PR badge - #153
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Adds provider-aware auto-merge status to PR data and surfaces it in the dashboard and CLI.
Changes:
- Parses GitHub auto-merge and Azure DevOps auto-complete state.
- Displays an auto-merge icon and CLI status flag.
- Adds provider, persistence, CLI, and dashboard coverage.
Show a summary per file
| File | Description |
|---|---|
src/Shared/Types.fs |
Adds auto-merge state to PrInfo. |
src/Server/PrStatus.fs |
Parses Azure DevOps auto-complete state. |
src/Server/GithubPrStatus.fs |
Parses GitHub auto-merge state. |
src/Server/MergedPrStore.fs |
Defaults restored merged PRs to no auto-merge. |
src/Server/DemoFixture.fs |
Demonstrates the indicator. |
src/Client/CardViews.fs |
Renders the auto-merge icon. |
src/Client/index.html |
Adds shared PR icon styling. |
src/Cli/Program.fs |
Adds the auto-merge flag. |
src/Tests/AzDoFixtureTests.fs |
Tests Azure DevOps parsing. |
src/Tests/GithubFixtureTests.fs |
Tests GitHub parsing. |
src/Tests/CliTests.fs |
Tests CLI formatting. |
src/Tests/DashboardTests.fs |
Tests dashboard rendering. |
src/Tests/MergedPrStoreTests.fs |
Tests fallback behavior. |
src/Tests/PrFilteringTests.fs |
Updates PR fixtures. |
src/Tests/SchedulerTests.fs |
Updates scheduler test data. |
src/Tests/fixtures/worktrees.json |
Adds serialized fixture values. |
src/Tests/fixtures/github/pr-list.json |
Adds enabled GitHub data. |
src/Tests/fixtures/github/pr-list-with-closed.json |
Adds null and merged GitHub cases. |
src/Tests/fixtures/azdo/pr-list.json |
Adds Azure DevOps cases. |
docs/spec/worktree-monitor.md |
Documents the indicator and persistence behavior. |
Review details
- Files reviewed: 20/20 changed files
- Comments generated: 0
- Review effort level: Medium
0101
force-pushed
the
auto-merge-indicator
branch
from
July 28, 2026 15:57
36d8e3e to
0542017
Compare
Adds AutoMergeEnabled to PrInfo, parsed from data already present in the existing PR-list responses (GitHub auto_merge, AzDo autoCompleteSetBy), so no extra provider calls. Both providers keep the field populated after a merge, so parsing forces it false for merged PRs. The dashboard renders a mauve check-in-circle glyph on the PR badge, and `tm status` gains a matching auto-merge flag. Copilot-Session: 19824f14-1931-440b-824f-7359cd257981
0101
force-pushed
the
auto-merge-indicator
branch
from
July 28, 2026 16:09
0542017 to
1228009
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
When a PR has GitHub auto-merge (or Azure DevOps auto-complete) set, it will merge itself as soon as the remaining checks and policies pass. Treemon showed no sign of this, so a worktree with a fully hands-off PR looked identical to one still waiting on a human to press merge.
Changes
AutoMergeEnabled: booladded toPrInfoinsrc/Shared/Types.fsauto_mergein/pulls(object →true,null/absent →false)autoCompleteSetByinaz repos pr list(identity →true,null/absent →false)falsefor merged PRs — the flag is only meaningful while the PR is open.MergedPrStorefallbacks are likewise alwaysfalse, and the fact is not persisted.autoMergeIconinCardViews.fs). The existing.conflict-iconCSS was generalized to a shared.pr-iconclass withconflict/auto-mergecolour modifiers.tm statusgains a matchingauto-mergeflag alongsidedraft/merged/conflicts.docs/spec/worktree-monitor.md.Tests
dotnet test src/Tests/Tests.fsproj --filter "Category=Fast"— 1710 passed, 0 failed (5m 27s).New coverage: GitHub and AzDo fixture parsing (set,
null, absent, and merged-PR cases), CLI flag rendering, dashboard badge markup, andMergedPrStorefallback.