forge pr list: filter by state and mark merged pull requests #193
Labels
No labels
blocked
bug
decision
duplicate
enhancement
help wanted
invalid
landed?
question
ready-to-merge
stale
wontfix
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
allod/tools#193
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Let
forge pr listenumerate closed and merged pull requests, so a caller can find the merged pull request that settled an issue without viewing every number the repository has ever issued.Primary goals:
forge pr list -s open|closed|all, the same flagforge issue listalready takes, defaulting toopenas today.-L <number>, and whatever pagingforge issue listgains from allod/tools#89 applies here too.Current state and specifics
forge pr listaccepts only-R;forge pr list -s closedexits withforge: unknown option for pr list: -s.forge pr view <n>printsState: closedfor a merged and an abandoned pull request alike, and theforge pr snapshotJSON carries no merged field either, so nothing in the tool distinguishes the two. The forge-groom skill inallod/memory(skills/forge-groom/SKILL.md, step 1) namesforge pr list -s closedas the source of merged evidence, and its close rule depends on telling merged from closed.The groom run on 2026-09-10 worked around it by viewing every number from 1 to the highest
refs/pull/*/headthe remote advertises, keeping the ones that answered as pull requests, and testinggit merge-base --is-ancestor refs/pull/<n> origin/masterin a scratch clone. That only works because merges in these repositories are fast-forward; a squash or rebase merge would leave every pull request looking unmerged.Scope
In: the
pr listflags and row format, and a merged indicator inpr viewandpr snapshotif it is cheapest to add in the same change. Out: issue list paging, tracked in allod/tools#89; timestamps in the view headers, tracked in allod/tools#194.