Skip to content

feat: add interactive GitHub issue-to-code wizard#266

Closed
rubenmarcus wants to merge 2 commits intomainfrom
feat/github-wizard
Closed

feat: add interactive GitHub issue-to-code wizard#266
rubenmarcus wants to merge 2 commits intomainfrom
feat/github-wizard

Conversation

@rubenmarcus
Copy link
Copy Markdown
Member

Summary

  • New ralph-starter github command — 4-step interactive wizard for building code from GitHub issues
  • Step 1: Repository input (owner/repo or URL)
  • Step 2: Issue selection (fetches open issues via gh CLI, numbered menu)
  • Step 3: Tech stack auto-detection from package.json
  • Step 4: Model selection based on installed agents
  • Delegates to runCommand() with --from github flags
  • Includes CLI docs page, sidebar entry, llms.txt and ai-index.json updates

Test plan

  • pnpm build — TypeScript compiles cleanly
  • pnpm test:run — all 213 tests pass
  • pnpm build in docs/ — site builds with 43 docs (was 42)
  • ralph-starter github — walks through 4-step wizard with a real repo
  • Docs page renders at /docs/cli/github
  • Sidebar shows github after figma in CLI Reference

🤖 Generated with Claude Code

New `ralph-starter github` command with 4-step interactive flow:
repo selection, issue picking, tech stack auto-detect, model choice.
Mirrors the Figma wizard pattern and delegates to runCommand.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@chatgpt-codex-connector
Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 6, 2026

Issue Linking Reminder

This PR doesn't appear to have a linked issue. Consider linking to:

  • This repo: Closes #123
  • ralph-ideas: Closes multivmlabs/ralph-ideas#123

Using Closes, Fixes, or Resolves will auto-close the issue when this PR is merged.


If this PR doesn't need an issue, you can ignore this message.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 6, 2026

✔️ Bundle Size Analysis

Metric Value
Base 2425.03 KB
PR 2446.03 KB
Diff 21.00 KB (0%)
Bundle breakdown
156K	dist/auth
32K	dist/automation
4.0K	dist/cli.d.ts
4.0K	dist/cli.d.ts.map
20K	dist/cli.js
12K	dist/cli.js.map
600K	dist/commands
28K	dist/config
4.0K	dist/index.d.ts
4.0K	dist/index.d.ts.map
4.0K	dist/index.js
4.0K	dist/index.js.map
896K	dist/integrations
84K	dist/llm
900K	dist/loop
188K	dist/mcp
32K	dist/presets
92K	dist/setup
40K	dist/skills
392K	dist/sources
76K	dist/ui
144K	dist/utils
336K	dist/wizard

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented Mar 6, 2026

Greptile Summary

This PR introduces a ralph-starter github command — a 4-step interactive wizard that mirrors the existing figma command but targets GitHub issues. It collects a repository, an open issue, a tech stack, and a model, then delegates to runCommand(). Docs, sidebar, llms.txt, and ai-index.json are all updated accordingly.

Key issues found:

  • documentCount and totalDocuments are both off by 1 in docs/static/ai-index.json: two new CLI documents (figma + github) were added, but the counters only increased by 1 each.
  • version in ai-index.json was downgraded from "1.0.0" to "0.4.0" — this appears to be an unintentional regression.
  • interface used instead of type for GitHubWizardOptions and GitHubIssue in src/commands/github.ts, contrary to the project's TypeScript conventions.
  • detectProjectStack and buildModelChoices are duplicated verbatim from figma.ts; extracting them to a shared utility would prevent drift.
  • fetchIssues uses shell string interpolation via execSync — using execFileSync with an arguments array would be more defensive.
  • Invalid custom model ID causes a hard exit rather than re-prompting the user, forcing a full wizard restart.

Confidence Score: 3/5

  • Mergeable after fixing the two off-by-one count bugs and the version downgrade in ai-index.json.
  • The core wizard logic is sound and consistent with the existing figma command. However, two factual data bugs in ai-index.json (miscounted documents and a version regression) would ship incorrect metadata to consumers, and there are a handful of code-quality issues worth addressing before merge.
  • docs/static/ai-index.json (count/version bugs) and src/commands/github.ts (interface vs type, code duplication).

Important Files Changed

Filename Overview
src/commands/github.ts New 4-step interactive wizard; has interface instead of type for both data types (custom rule violation), detectProjectStack/buildModelChoices duplicated from figma.ts, shell string interpolation in fetchIssues, and invalid-model path exits the wizard rather than re-prompting.
src/cli.ts Clean addition of the github command registration, consistent with the existing figma command pattern.
docs/static/ai-index.json Adds figma and github CLI doc entries, but documentCount for the Cli category is 15 (should be 16) and totalDocuments is 41 (should be 42); also regresses version from 1.0.0 to 0.4.0.
docs/docs/cli/github.md Well-written documentation page covering all 4 wizard steps, options table, example session, and prerequisites.
docs/sidebars.ts Correctly adds cli/figma and cli/github to the CLI Reference sidebar section.
docs/static/llms.txt Correctly adds figma and github CLI doc links in alphabetical order.

Sequence Diagram

sequenceDiagram
    actor User
    participant CLI as ralph-starter CLI
    participant Wizard as githubCommand()
    participant Agents as detectAvailableAgents()
    participant GH as gh CLI (execSync)
    participant Run as runCommand()

    User->>CLI: ralph-starter github [options]
    CLI->>Wizard: githubCommand(options)
    Wizard->>Agents: detectAvailableAgents()
    Agents-->>Wizard: available agents (claude-code, codex, …)
    Wizard-->>User: Step 1 — Enter repository (owner/repo or URL)
    User->>Wizard: e.g. acme/webapp
    Wizard->>GH: gh issue list -R acme/webapp --json …
    GH-->>Wizard: GitHubIssue[]
    Wizard-->>User: Step 2 — Numbered issue list
    User->>Wizard: Pick issue number
    Wizard-->>User: Step 3 — Tech stack list (auto-detected default)
    User->>Wizard: Pick or type stack
    Wizard-->>User: Step 4 — Model list (agent-aware)
    User->>Wizard: Pick or type model
    Wizard->>Run: runCommand(fullTask, { from: 'github', project, issue, model, … })
    Run-->>User: Autonomous coding loop output
Loading

Last reviewed commit: e1454e0

Comment thread src/commands/github.ts
Comment thread docs/static/ai-index.json
Comment thread docs/static/ai-index.json
Comment thread docs/static/ai-index.json
Comment thread src/commands/github.ts
Comment thread src/commands/github.ts
Comment thread src/commands/github.ts
The cli/figma doc page does not exist — removed from sidebar and
updated all links to point to sources/figma instead.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 8, 2026

🔗 Docs Preview

Preview URL: https://feat-github-wizard.ralph-starter-docs.pages.dev

This preview was deployed from the latest commit on this PR.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 8, 2026

This PR has been automatically marked as stale because it has not had recent activity.
It will be closed in 7 days if no further activity occurs.
Please update or comment if this PR is still in progress.

@github-actions github-actions Bot added the stale label Apr 8, 2026
@rubenmarcus
Copy link
Copy Markdown
Member Author

Superseded by #270 which has been merged with the updated GitHub wizard implementation.

@rubenmarcus rubenmarcus closed this Apr 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant