gh-stack sync --prune deletes merged-PR refs during sync
Introduced 2026-05-15 · score 0.94
HOW TO USE IT
When syncing a stack with merged PRs, run `gh stack sync --prune` to automatically delete their local branches. The documentation does not confirm deletion of remote-tracking refs.
gh stack sync --pruneWHY THIS HELPS
During sync, remove local branches and remote-tracking refs for merged pull requests.
REQUIREMENTS AND LIMITATIONS
- Version: v0.0.4
- --prune: Automatically delete local branches for merged PRs during sync.
- Prerequisite: Install the GitHub CLI extension with `gh extension install github/gh-stack`; the docs require GitHub CLI v2.0+ and Git 2.36+.
- Docs conflict: The release note says pruning deletes local branches and remote-tracking refs. The command documentation describes deletion of local branches only and does not confirm remote-tracking ref deletion.
FIRST-PARTY EVIDENCE
Check the installed version and the source before using it. Entry JSON