You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+147Lines changed: 147 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -47,6 +47,37 @@ The result is a graveyard of GitHub issues that say "Fix auth" with zero follow-
47
47
48
48
So I built MGW to be the responsible adult in the room. I point it at an issue, it does all the paperwork I was never going to do, and my GitHub history finally looks like a person who has their life together. It's the professional version of me that answers emails on time and keeps a clean desk — except it's a dozen Markdown files, a Node CLI, and Claude doing all the work.
49
49
50
+
## Who This Is For
51
+
52
+
MGW is for **solo developers and small teams using Claude Code** who want their GitHub history to reflect the work they actually did — without spending time on project management.
53
+
54
+
**You'll get the most out of MGW if you:**
55
+
56
+
- Use [Claude Code](https://docs.anthropic.com/en/docs/claude-code/overview) as your primary development tool
57
+
- Have a pile of GitHub issues that never get proper status updates, PR descriptions, or cross-references
58
+
- Want a repeatable issue-to-PR pipeline that handles triage, planning, execution, and documentation automatically
59
+
- Work across multiple projects and lose context switching between GitHub and your terminal
60
+
61
+
**When to use MGW vs. Claude Code directly:**
62
+
63
+
| Scenario | Use |
64
+
|----------|-----|
65
+
| One-off code changes with no issue tracking | Claude Code directly |
66
+
| Issues that need triage, planning, status updates, and PRs | MGW |
67
+
| Executing a backlog of issues in dependency order | MGW (`/mgw:milestone`) |
68
+
| Scaffolding a new project from a description | MGW (`/mgw:project`) |
69
+
| Quick code question or file edit | Claude Code directly |
70
+
71
+
**Prerequisites:**
72
+
73
+
- Node.js >= 18
74
+
-[Claude Code](https://docs.anthropic.com/en/docs/claude-code/overview) CLI installed and working
75
+
-[GitHub CLI](https://cli.github.com/) (`gh`) installed and authenticated (`gh auth status`)
76
+
-[Get Shit Done](https://github.com/glittercowboy/get-shit-done) (GSD) installed in Claude Code
77
+
- A GitHub repository with issues enabled
78
+
79
+
If you're already using Claude Code and GSD for development, MGW is the missing piece that connects your work back to GitHub. If you're not using either yet, start with Claude Code, then add GSD, then add MGW.
Seriously, if you're using Claude Code for development, go install GSD. MGW is just the GitHub layer on top.
323
354
355
+
## Troubleshooting
356
+
357
+
### GitHub CLI not authenticated
358
+
359
+
```
360
+
Error: gh: not logged in
361
+
```
362
+
363
+
Run `gh auth status` to check. If not authenticated:
364
+
365
+
```bash
366
+
gh auth login
367
+
# Select GitHub.com, HTTPS, and authenticate via browser
368
+
```
369
+
370
+
MGW requires the `repo` scope. If you're authenticated but getting permission errors, re-authenticate with the correct scopes:
371
+
372
+
```bash
373
+
gh auth login --scopes repo
374
+
```
375
+
376
+
### GSD not installed
377
+
378
+
```
379
+
Error: GSD slash commands not found
380
+
```
381
+
382
+
MGW delegates planning and execution to [Get Shit Done](https://github.com/glittercowboy/get-shit-done). Install it following the GSD README, then verify the commands are available in Claude Code:
383
+
384
+
```
385
+
/gsd:quick --help
386
+
```
387
+
388
+
### State file issues (.mgw/ directory)
389
+
390
+
**State drift** — Local `.mgw/` state can fall out of sync with GitHub if you merge PRs from the web UI, close issues manually, or work from a different machine. Run sync to reconcile:
391
+
392
+
```
393
+
/mgw:sync
394
+
```
395
+
396
+
**Corrupted state** — If `.mgw/` gets into a bad state, you can safely delete it and re-initialize:
397
+
398
+
```bash
399
+
rm -rf .mgw/
400
+
/mgw:init
401
+
```
402
+
403
+
This won't affect anything on GitHub. The `.mgw/` directory is local-only and gitignored.
404
+
405
+
**Missing .mgw/ directory** — If you cloned a repo that uses MGW but don't have a `.mgw/` directory, run init:
406
+
407
+
```
408
+
/mgw:init
409
+
```
410
+
411
+
### Worktree cleanup
412
+
413
+
MGW creates git worktrees in `.worktrees/` for each issue pipeline. If a pipeline fails mid-execution, stale worktrees can accumulate:
414
+
415
+
```bash
416
+
# List active worktrees
417
+
git worktree list
418
+
419
+
# Remove a specific stale worktree
420
+
git worktree remove .worktrees/issue/42-fix-auth
421
+
422
+
# Prune all stale worktree references
423
+
git worktree prune
424
+
```
425
+
426
+
The associated branches are not deleted automatically. Clean them up after removing the worktree:
427
+
428
+
```bash
429
+
git branch -d issue/42-fix-auth
430
+
```
431
+
432
+
### Rate limiting
433
+
434
+
MGW posts comments on GitHub issues at each pipeline stage. If you're executing many issues in quick succession (e.g., via `/mgw:milestone`), you may hit GitHub's API rate limits:
435
+
436
+
```
437
+
Error: API rate limit exceeded
438
+
```
439
+
440
+
Check your current rate limit status:
441
+
442
+
```bash
443
+
gh api rate_limit --jq '.resources.core'
444
+
```
445
+
446
+
If rate-limited, wait for the reset window (usually under an hour) or reduce the number of concurrent pipelines. Authenticated requests get 5,000 requests per hour — plenty for normal use, but milestone-level execution with many issues can approach the limit.
447
+
448
+
### Common errors
449
+
450
+
| Error | Cause | Fix |
451
+
|-------|-------|-----|
452
+
|`Issue #N not found`| Issue doesn't exist or is in a different repo | Check the issue number and ensure you're in the correct repo |
453
+
|`Branch already exists`| A previous pipeline run created the branch | Delete the branch (`git branch -D issue/N-...`) or use the existing one |
454
+
|`No GSD route determined`| Triage couldn't determine issue scope | Run `/mgw:issue N` manually to inspect the triage output |
455
+
|`Merge conflict in worktree`| Main branch diverged during execution | Resolve conflicts in the worktree, then resume with `/mgw:run N`|
0 commit comments