$npx -y skills add AlexAI-MCP/hermes-CCC --skill github-issuesGitHub issue management — create, update, label, milestone, and link issues to PRs via gh CLI or curl fallback.
| 1 | # GitHub Issues |
| 2 | |
| 3 | Full issue lifecycle management using the `gh` CLI. Every command has a `curl` fallback for machines without `gh`. |
| 4 | |
| 5 | ## Prerequisites |
| 6 | |
| 7 | - GitHub CLI: `gh auth login` (or set `GH_TOKEN` env var) |
| 8 | - curl fallback: set `GITHUB_TOKEN` and know your `OWNER/REPO` |
| 9 | |
| 10 | ```bash |
| 11 | export OWNER=myorg |
| 12 | export REPO=myrepo |
| 13 | export GITHUB_TOKEN=ghp_... |
| 14 | ``` |
| 15 | |
| 16 | --- |
| 17 | |
| 18 | ## List Issues |
| 19 | |
| 20 | ```bash |
| 21 | # Open issues |
| 22 | gh issue list |
| 23 | |
| 24 | # Filter by label, assignee, state |
| 25 | gh issue list --state open --label bug --assignee @me |
| 26 | |
| 27 | # All states |
| 28 | gh issue list --state all --limit 50 |
| 29 | |
| 30 | # curl fallback |
| 31 | curl -H "Authorization: token $GITHUB_TOKEN" \ |
| 32 | "https://api.github.com/repos/$OWNER/$REPO/issues?state=open&per_page=20" |
| 33 | ``` |
| 34 | |
| 35 | --- |
| 36 | |
| 37 | ## View an Issue |
| 38 | |
| 39 | ```bash |
| 40 | gh issue view 123 |
| 41 | |
| 42 | # Open in browser |
| 43 | gh issue view 123 --web |
| 44 | |
| 45 | # curl fallback |
| 46 | curl -H "Authorization: token $GITHUB_TOKEN" \ |
| 47 | "https://api.github.com/repos/$OWNER/$REPO/issues/123" |
| 48 | ``` |
| 49 | |
| 50 | --- |
| 51 | |
| 52 | ## Create an Issue |
| 53 | |
| 54 | ```bash |
| 55 | gh issue create \ |
| 56 | --title "Fix null pointer in auth module" \ |
| 57 | --body "Steps to reproduce:\n1. ...\n2. ..." \ |
| 58 | --label "bug,priority:high" \ |
| 59 | --assignee @me |
| 60 | |
| 61 | # Interactive |
| 62 | gh issue create |
| 63 | |
| 64 | # curl fallback |
| 65 | curl -X POST \ |
| 66 | -H "Authorization: token $GITHUB_TOKEN" \ |
| 67 | -H "Content-Type: application/json" \ |
| 68 | "https://api.github.com/repos/$OWNER/$REPO/issues" \ |
| 69 | -d '{"title":"Fix null pointer","body":"...","labels":["bug"]}' |
| 70 | ``` |
| 71 | |
| 72 | --- |
| 73 | |
| 74 | ## Edit an Issue |
| 75 | |
| 76 | ```bash |
| 77 | # Add label |
| 78 | gh issue edit 123 --add-label "priority:high" |
| 79 | |
| 80 | # Remove label |
| 81 | gh issue edit 123 --remove-label "needs-triage" |
| 82 | |
| 83 | # Change assignee |
| 84 | gh issue edit 123 --add-assignee username |
| 85 | |
| 86 | # Set milestone |
| 87 | gh issue edit 123 --milestone "v2.0" |
| 88 | |
| 89 | # Change title |
| 90 | gh issue edit 123 --title "New title" |
| 91 | ``` |
| 92 | |
| 93 | --- |
| 94 | |
| 95 | ## Comment on an Issue |
| 96 | |
| 97 | ```bash |
| 98 | gh issue comment 123 --body "Looking into this now." |
| 99 | |
| 100 | # curl fallback |
| 101 | curl -X POST \ |
| 102 | -H "Authorization: token $GITHUB_TOKEN" \ |
| 103 | -H "Content-Type: application/json" \ |
| 104 | "https://api.github.com/repos/$OWNER/$REPO/issues/123/comments" \ |
| 105 | -d '{"body":"Looking into this now."}' |
| 106 | ``` |
| 107 | |
| 108 | --- |
| 109 | |
| 110 | ## Close / Reopen an Issue |
| 111 | |
| 112 | ```bash |
| 113 | gh issue close 123 |
| 114 | gh issue close 123 --reason "completed" |
| 115 | gh issue close 123 --comment "Fixed in #456" |
| 116 | |
| 117 | gh issue reopen 123 |
| 118 | ``` |
| 119 | |
| 120 | --- |
| 121 | |
| 122 | ## Search Issues |
| 123 | |
| 124 | ```bash |
| 125 | gh issue list --search "error in production" |
| 126 | gh issue list --search "label:bug created:>2024-01-01" |
| 127 | |
| 128 | # GitHub search syntax |
| 129 | gh issue list --search "is:open is:issue assignee:@me" |
| 130 | ``` |
| 131 | |
| 132 | --- |
| 133 | |
| 134 | ## Link Issues to PRs |
| 135 | |
| 136 | Reference issues in PR body or commits: |
| 137 | ``` |
| 138 | Fixes #123 |
| 139 | Closes #456 |
| 140 | Resolves #789 |
| 141 | ``` |
| 142 | |
| 143 | GitHub auto-closes linked issues when PR merges. |
| 144 | |
| 145 | --- |
| 146 | |
| 147 | ## Bulk Operations |
| 148 | |
| 149 | ```bash |
| 150 | # Close all issues with a label |
| 151 | gh issue list --label "wontfix" --json number --jq '.[].number' | \ |
| 152 | xargs -I{} gh issue close {} --reason "not planned" |
| 153 | |
| 154 | # List issues as JSON |
| 155 | gh issue list --json number,title,labels,assignees --limit 100 |
| 156 | ``` |
| 157 | |
| 158 | --- |
| 159 | |
| 160 | ## Milestones |
| 161 | |
| 162 | ```bash |
| 163 | # List milestones |
| 164 | gh api repos/$OWNER/$REPO/milestones |
| 165 | |
| 166 | # Create milestone |
| 167 | gh api repos/$OWNER/$REPO/milestones \ |
| 168 | --method POST \ |
| 169 | -f title="v2.0" \ |
| 170 | -f due_on="2024-06-01T00:00:00Z" |
| 171 | ``` |
| 172 | |
| 173 | --- |
| 174 | |
| 175 | ## Labels |
| 176 | |
| 177 | ```bash |
| 178 | # List labels |
| 179 | gh label list |
| 180 | |
| 181 | # Create label |
| 182 | gh label create "priority:high" --color FF0000 --description "Urgent" |
| 183 | |
| 184 | # Clone labels from another repo |
| 185 | gh label clone owner/source-repo |
| 186 | ``` |
| 187 | |
| 188 | --- |
| 189 | |
| 190 | ## Issue Templates |
| 191 | |
| 192 | Create `.github/ISSUE_TEMPLATE/bug_report.md`: |
| 193 | ```markdown |
| 194 | --- |
| 195 | name: Bug Report |
| 196 | about: Report a bug |
| 197 | labels: bug |
| 198 | --- |
| 199 | |
| 200 | ## Description |
| 201 | ## Steps to Reproduce |
| 202 | ## Expected vs Actual |
| 203 | ## Environment |
| 204 | ``` |