Skip to content

feat(repo): show tool-specific next steps after repo init#1443

Merged
stack72 merged 1 commit into
mainfrom
worktree-lively-puzzling-canyon
May 24, 2026
Merged

feat(repo): show tool-specific next steps after repo init#1443
stack72 merged 1 commit into
mainfrom
worktree-lively-puzzling-canyon

Conversation

@stack72
Copy link
Copy Markdown
Contributor

@stack72 stack72 commented May 24, 2026

Summary

  • After swamp repo init, show a "What's next:" section with tool-specific onboarding instructions (e.g. "Start Claude Code and run /swamp-getting-started" for claude, "Open this project in Cursor and run /swamp-getting-started" for cursor, etc.)
  • Include a docs link to the manual at swamp-club.com/manual
  • Fall back to "Run swamp --help" when no tools are enrolled (--tool none)
  • JSON renderer includes a nextSteps array for programmatic consumers

Test Plan

  • Unit tests for all tool-specific next steps (claude, cursor, multi-tool, no-tool)
  • Unit tests for JSON output including nextSteps array
  • All 8 tests pass, existing upgrade renderer tests unaffected
  • deno fmt, deno lint, deno check all clean

🤖 Generated with Claude Code

After initializing a repository, users had no guidance on what to do
next. Now the init output includes a "What's next:" section with
tool-specific onboarding instructions (e.g. "Start Claude Code and run
/swamp-getting-started") and a link to the manual. The JSON renderer
also includes a `nextSteps` array for programmatic consumers.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CLI UX Review

Blocking

None.

Suggestions

  1. JSON nextSteps missing the manual link (src/presentation/renderers/repo_init.ts, JsonRepoInitRenderer): Log mode always appends → Read the manual at https://swamp-club.com/manual regardless of enrolled tools, but the JSON renderer's nextSteps array only contains tool-specific entries (or the --help fallback). A script consuming nextSteps to build onboarding guidance would silently omit the docs link. Consider pushing the manual URL into nextSteps in the JSON renderer the same way it's always surfaced in log mode.

Verdict

PASS — no blocking issues. The "What's next:" section is clear, well-formatted, and consistent with the existing renderer's style. Tool-specific instructions are accurate and actionable, and the no-tool fallback to swamp --help is a sensible default. JSON output correctly extends e.data with a nextSteps array without dropping any existing fields.

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

Clean, well-scoped PR. The presentation-layer placement of TOOL_NEXT_STEPS is correct — this is rendering concern, not domain logic. Import boundaries are respected (libswamp types via mod.ts, no internal path imports). Test coverage is thorough with 6 new tests covering log/json × single-tool/multi-tool/no-tool. The RepoInitData shape in makeInitData matches the interface exactly. No security concerns.

Blocking Issues

None.

Suggestions

  1. JSON nextSteps missing the manual link — The log renderer always appends "Read the manual at https://swamp-club.com/manual" (line 157), but the JSON renderer doesn't include it in the nextSteps array (lines 170-177). Programmatic consumers won't see it. Consider adding steps.push("Read the manual at https://swamp-club.com/manual") before the JSON.stringify call if the intent is parity between modes.

  2. assertStringIncludes(output, "manual") test missing — Neither log nor JSON test asserts the manual link appears. A one-liner assertStringIncludes(output, "swamp-club.com/manual") in the claude-tool log test would lock in the behavior cheaply.

@stack72 stack72 merged commit bfea476 into main May 24, 2026
11 checks passed
@stack72 stack72 deleted the worktree-lively-puzzling-canyon branch May 24, 2026 20:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant