close-issue

Close GitHub issues, linked pull requests, and feature branches.

Updated Feb 6, 2026
One-click install
npx skills add https://github.com/khwerhahn/okuban.nvim --skill close-issue-khwerhahn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: close-issue
Source: https://github.com/khwerhahn/okuban.nvim/tree/main/.claude/skills/close-issue
Command: npx skills add https://github.com/khwerhahn/okuban.nvim --skill close-issue-khwerhahn

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Reduce the manual, error-prone work of finalizing completed issues by verifying completion, updating okuban kanban labels, closing stale or superseded pull requests, and removing associated feature branches so repositories stay tidy and reflect true status.

Core Features & Use Cases

  • Automated Kanban Transition: Detect and remove existing okuban labels and set the issue to okuban:done to mark completion on your in-editor board.
  • PR and Branch Cleanup: Find linked PRs by Fixes/Closes references or branch naming patterns, close open PRs with a comment, and delete matching remote and local branches while skipping protected refs such as main, HEAD, and release-please.
  • Finalization and Reporting: Comment on and close the issue, then provide a concise summary listing closed PRs and deleted branches for auditability. Use case: After merging or completing work for an issue, run this workflow to automatically finalize the issue, remove stale PRs, and purge leftover branches.

Quick Start

Run the close-issue skill with the issue number to verify the issue, close linked pull requests, move the okuban label to done, delete matching branches, and close the issue.

Frequently Asked Questions about close-issue

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automatically close GitHub issues and clean up linked branches?

To automatically close GitHub issues and clean up linked branches, you run this skill with the issue number to verify state, close linked pull requests, update okuban labels to done, delete matching remote and local branches, and comment a final summary.

How does automated GitHub issue closure discover linked pull requests?

Automated GitHub issue closure discovers linked pull requests by scanning for Fixes or Closes references within PR descriptions and matching branch naming patterns associated with the target issue.

Does automated branch cleanup delete protected refs like main or release branches?

Automated branch cleanup explicitly skips protected refs such as main, HEAD, and release-please, ensuring only matching feature branches are deleted from both remote and local repositories.

Can I use this GitHub issue finalization workflow without okuban kanban labels?

This workflow is designed for repositories using okuban label conventions, so it expects existing okuban kanban labels to detect, remove, and transition the issue state to okuban:done.

What is the best way to automate kanban transitions when closing completed GitHub issues?

The best way to automate kanban transitions when closing completed GitHub issues is to run a workflow that detects existing okuban labels, removes them, applies the okuban:done label, and closes the issue with a concise audit summary.

Why does closing a GitHub issue leave stale pull requests and feature branches behind?

Closing a GitHub issue leaves stale pull requests and branches behind because native closure does not discover PRs by Fixes/Closes references or delete matching remote and local branches, requiring a separate cleanup workflow to finalize the work.