Helps draft well-structured GitHub issues with proper formatting, context, and best practices. Use when the user wants to "create an issue", "draft an issue", "write a bug report", or "create a feature request".
Drafts well-structured GitHub issues with proper templates, context, and metadata.
/plugin marketplace add vdemeester/claude-code-plugins/plugin install gh-tools@vdemeester-claude-code-pluginsAssists in creating well-structured, comprehensive GitHub issues following best practices.
Goal: Gather information about what issue needs to be created
Actions:
Ask the user clarifying questions:
Based on the issue type, determine what information is needed:
Ask if the user wants you to gather context from the codebase:
Goal: Collect relevant information from the codebase if requested
Actions:
If user wants codebase context, gather relevant information:
For bugs:
For features:
For tasks:
Summarize findings to user
Goal: Create a well-structured issue following best practices
Actions:
Based on issue type, create appropriate structure:
Bug Report Template:
## Bug Description
[Clear description of the bug]
## Steps to Reproduce
1. [Step 1]
2. [Step 2]
3. [Step 3]
## Expected Behavior
[What should happen]
## Actual Behavior
[What actually happens]
## Environment
- OS: [e.g., macOS 14.1, Ubuntu 22.04]
- Browser/Tool: [e.g., Chrome 120, Node 20.10]
- Version: [app/package version]
## Additional Context
[Any other relevant information]
## Error Logs/Screenshots
[Relevant logs or error messages]
Feature Request Template:
## Feature Description
[What feature are you requesting?]
## User Story
As a [user type], I want [goal] so that [benefit].
## Proposed Implementation
[How you envision this working]
- [Implementation detail 1]
- [Implementation detail 2]
## Benefits
- [Benefit 1]
- [Benefit 2]
## Alternatives Considered
[Other approaches you've thought about and why they weren't chosen]
## Additional Context
[Any other relevant information, mockups, references]
Task/Chore Template:
## Task
[Description of what needs to be done]
## Checklist
- [ ] [Subtask 1]
- [ ] [Subtask 2]
- [ ] [Subtask 3]
## Dependencies
[Any prerequisites or related work]
## Acceptance Criteria
- [ ] [Criterion 1]
- [ ] [Criterion 2]
## Notes
[Any additional context or considerations]
Documentation Template:
## What Needs Documentation
[What feature/process needs documenting]
## Target Audience
[Who will read this documentation?]
## Key Topics to Cover
- [Topic 1]
- [Topic 2]
- [Topic 3]
## Current State
[What documentation exists already, if any]
## Proposed Structure
[Outline of how documentation should be organized]
Fill in the template with information gathered from user and codebase
Add appropriate metadata:
Goal: Present draft to user and refine based on feedback
Actions:
Present the drafted issue in a clear format:
## Proposed Issue
**Title**: [Concise, descriptive title]
**Body**:
[Full issue body]
**Suggested Labels**: bug, high-priority
**Suggested Assignee**: @username
**Suggested Milestone**: v2.0
Ask user:
Make requested changes
Goal: Provide ready-to-use command for creating the issue
Actions:
Generate the appropriate gh issue create command:
For simple issues:
gh issue create \
--title "Issue title" \
--body "Issue description" \
--label "bug,high-priority" \
--assignee @me
For complex issues (recommended):
--body-file optionExample:
# Save this to issue-body.md
cat > /tmp/issue-body.md <<'EOF'
[Full issue body here]
EOF
# Then run:
gh issue create \
--title "Add user authentication" \
--body-file /tmp/issue-body.md \
--label "enhancement,security" \
--assignee @me \
--milestone "v2.0"
Ask user if they want you to:
If user wants to create now:
gh issue create commandGood examples:
Bad examples:
Input: User says "The login page crashes when I submit the form"
Output:
**Title**: Login form submission causes page crash
**Body**:
## Bug Description
The login page crashes when submitting the login form with any credentials.
## Steps to Reproduce
1. Navigate to /login
2. Enter any username and password
3. Click "Sign In" button
4. Page crashes with white screen
## Expected Behavior
User should be authenticated and redirected to the dashboard.
## Actual Behavior
Page displays blank white screen. Console shows: "TypeError: Cannot read property 'token' of undefined at login.ts:45"
## Environment
- Browser: Safari 17.1 (macOS)
- App Version: 2.3.4
- Tested: Also reproduces on Chrome 120
## Additional Context
- Issue started after commit abc123f
- Works fine on staging environment
- Only affects production build
## Error Details
TypeError: Cannot read property 'token' of undefined at handleLoginSuccess (login.ts:45) at processResponse (api.ts:123)
**Suggested Labels**: bug, high-priority, production
**Suggested Assignee**: @auth-team
Input: User wants to add export functionality
Output:
**Title**: Add CSV export functionality for user reports
**Body**:
## Feature Description
Add ability to export user activity reports as CSV files for external analysis.
## User Story
As an administrator, I want to export user reports as CSV so that I can analyze data in Excel or import into other systems.
## Proposed Implementation
- Add "Export to CSV" button on reports page
- Generate CSV with columns: user_id, username, last_login, activity_count, status
- Include date range in filename (e.g., users_2024-01-15_to_2024-01-22.csv)
- Show download progress for large exports
## Benefits
- Enables offline data analysis
- Supports integration with external BI tools
- Improves administrator workflow efficiency
- Reduces manual data copying
## Alternatives Considered
- JSON export: Less user-friendly for non-technical users
- API endpoint only: Requires technical knowledge
- PDF export: Not suitable for data processing
## Technical Notes
Files to modify:
- src/reports/ReportsPage.tsx (add export button)
- src/api/reports.ts (add CSV generation endpoint)
- src/utils/csv.ts (CSV formatting utility)
**Suggested Labels**: enhancement, reports, good-first-issue
**Suggested Milestone**: Q1 2024
If gh command fails:
gh is installed: gh --versiongh auth statusIf duplicate issue might exist:
gh issue list --search "keywords"If required info missing:
Always provide:
Example final output:
## Drafted Issue Ready
**Title**: Login fails with valid credentials on mobile Safari
**Body**: [Full formatted body]
**Metadata**:
- Labels: bug, high-priority, mobile
- Assignee: @me
- Milestone: v2.1
**Command to create**:
```bash
cat > /tmp/issue-body.md <<'EOF'
[Issue body content]
EOF
gh issue create \
--title "Login fails with valid credentials on mobile Safari" \
--body-file /tmp/issue-body.md \
--label "bug,high-priority,mobile" \
--assignee @me \
--milestone "v2.1"
Would you like me to create this issue now?
Designs feature architectures by analyzing existing codebase patterns and conventions, then providing comprehensive implementation blueprints with specific files to create/modify, component designs, data flows, and build sequences