Get the FREE Ultimate OpenClaw Setup Guide →

gh-issue-reopen

npx machina-cli add skill dceoy/github-cli-agent-skills/gh-issue-reopen --openclaw
Files (1)
SKILL.md
1.5 KB

GitHub Issue Reopen

When to use

  • The user asks to reopen a closed issue.
  • Issue was closed prematurely or needs more work.
  • Bug reoccurred after being marked fixed.

Inputs to confirm

  • Issue number or URL.
  • Optional reopening comment.
  • Target repo if not current (--repo OWNER/REPO).

Workflow

  1. Verify auth:
    gh --version
    gh auth status
    
  2. Check issue current state:
    gh issue view 123 --json number,title,state,stateReason
    
  3. Reopen the issue:
    gh issue reopen 123
    gh issue reopen 123 --comment "Reopening: bug reoccurred in v2.1"
    
  4. Verify reopening:
    gh issue view 123 --json state
    

Examples

# Simple reopen
gh issue reopen 123

# Reopen with explanation
gh issue reopen 123 --comment "Issue still reproducible on latest version."

# Reopen by URL
gh issue reopen https://github.com/owner/repo/issues/123

Flags reference

FlagDescription
-c, --commentAdd a reopening comment

Notes

  • Only closed issues can be reopened.
  • Adding a comment helps track why the issue was reopened.
  • Arguments accept issue number or URL.

References

Source

git clone https://github.com/dceoy/github-cli-agent-skills/blob/main/skills/gh-issue-reopen/SKILL.mdView on GitHub

Overview

This skill reopens a closed GitHub issue using the gh CLI. It supports an optional --comment to explain why the issue is being reopened and can target a specific repository with --repo. It guides you through verifying authentication, checking issue state, executing the reopen, and confirming the new state.

How This Skill Works

First, verify your authentication with gh --version and gh auth status. Then inspect the issue state with gh issue view <num> --json number,state. Finally, reopen the issue with gh issue reopen <num> [--comment "Your reason"] and verify the new state with gh issue view <num> --json state.

When to Use It

  • User requests reopening a closed issue.
  • Issue was closed prematurely or needs more work.
  • Bug reoccurred after being marked fixed.
  • Need to add a reopening comment explaining why.
  • Reopen in a different repository with --repo.

Quick Start

  1. Step 1: Verify authentication with gh --version and gh auth status.
  2. Step 2: Check the issue state with gh issue view 123 --json number,state.
  3. Step 3: Reopen the issue (with optional --comment) and verify with gh issue view 123 --json state.

Best Practices

  • Verify authentication with gh --version and gh auth status.
  • Check current issue state with gh issue view and --json.
  • Provide a clear --comment explaining the reason for reopening.
  • Specify the correct repository with --repo when not in the target.
  • Verify reopening by rechecking the issue state after reopen.

Example Use Cases

  • gh issue reopen 123
  • gh issue reopen 123 --comment "Issue still reproducible on latest version."
  • gh issue reopen https://github.com/owner/repo/issues/123
  • gh issue reopen 123 --repo owner/repo
  • gh issue reopen 123 --comment "Reopening: not resolved in v2.1" --repo owner/repo

Frequently Asked Questions

Add this skill to your agents
Sponsor this space

Reach thousands of developers