Skip to content

docs: warn the assistant that tuiui launch skips the CLI-tool wrapper#46

Open
jaylfc wants to merge 2 commits into
mainfrom
docs/auto-freshness-20260706
Open

docs: warn the assistant that tuiui launch skips the CLI-tool wrapper#46
jaylfc wants to merge 2 commits into
mainfrom
docs/auto-freshness-20260706

Conversation

@jaylfc

@jaylfc jaylfc commented Jul 6, 2026

Copy link
Copy Markdown
Owner

What's stale

Routine docs-freshness audit found agent/DESKTOP.md describing tuiui launch <command> [args…] with no caveat about CLI-tagged catalog tools (the ~52 entries with "cli": true — gum, himalaya, khal, dust, …).

Traced the code: the help-then-shell wrapper added in commit 2a01eca (cli_wrap, sh -lc '<bin> --help; exec "$SHELL"') is only applied by the launcher-menu/Spotlight/Store UI paths (launch_entry / store_activate in src/session.rs). The ClientMsg::Launch handler that tuiui launch sends (src/main.rssession.rs::launch/launch_in) spawns the bare command directly and never calls cli_wrap. So an assistant-driven tuiui launch gum still opens a window that prints usage and exits immediately — the exact bug the CLI-tools feature was built to fix, just reachable through a different launch path.

Fix

Added a note to agent/DESKTOP.md documenting the gap and the workaround: wrap the command in sh -lc '<bin> --help; exec "$SHELL"' before passing it to tuiui launch.

Scope check

  • No code changes — agent/DESKTOP.md only.
  • The underlying gap (the ClientMsg::Launch path not calling cli_wrap) is a real code-level inconsistency, out of scope for a docs-only fix — flagging it separately for a proper fix in session.rs.

Generated by Claude Code

Summary by CodeRabbit

  • Documentation
    • Clarified desktop command behavior when launching CLI tools directly.
    • Added guidance for using a shell wrapper to view help output before continuing into an interactive shell.

Routine docs-freshness audit: agent/DESKTOP.md tells the assistant to run
`tuiui launch <command>`, but that path (ClientMsg::Launch -> launch() in
session.rs) spawns the bare command directly and never calls cli_wrap. The
help-then-shell wrapper added for CLI-tagged catalog tools (commit 2a01eca)
only fires through the launcher menu/Spotlight/Store UI paths, so an
assistant-driven `tuiui launch gum` (or any of the ~52 "cli": true entries)
still opens a window that prints usage and exits immediately - the exact bug
that feature was built to fix, just on a different launch path.

Documents the gap and the working workaround (wrap the command in
`sh -lc '<bin> --help; exec "$SHELL"'` before passing it to tuiui launch)
so the assistant doesn't hit it. The underlying gap in the launch() path
itself is a code fix, out of scope here.
@qodo-code-review

Copy link
Copy Markdown

Qodo reviews are paused for this user.

Troubleshooting steps vary by plan Learn more →

On a Teams plan?
Reviews resume once this user has a paid seat and their Git account is linked in Qodo.
Link Git account →

Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center?
These require an Enterprise plan - Contact us
Contact us →

@coderabbitai

coderabbitai Bot commented Jul 6, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@jaylfc, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 57 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 61abebca-6feb-4fc9-b029-7426d9d402e5

📥 Commits

Reviewing files that changed from the base of the PR and between d84756a and f226788.

📒 Files selected for processing (1)
  • agent/DESKTOP.md
📝 Walkthrough

Walkthrough

This change adds documentation to agent/DESKTOP.md, clarifying that catalog entries tagged as CLI tools print usage and exit when launched directly, and provides an alternate command to obtain an interactive shell.

Changes

Documentation update

Layer / File(s) Summary
Add CLI escape hatch documentation
agent/DESKTOP.md
Documents that CLI-tagged catalog entries print usage/help and exit rather than opening a shell, and provides an alternate tuiui launch sh -lc '<bin> --help; exec "$SHELL"' command.

Estimated code review effort: 1 (Trivial) | ~2 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the documentation update about tuiui launch bypassing the CLI-tool wrapper.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/auto-freshness-20260706

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Comment thread agent/DESKTOP.md Outdated
@kilo-code-bot

kilo-code-bot Bot commented Jul 6, 2026

Copy link
Copy Markdown

Code Review Summary

Status: No Issues Found | Recommendation: Merge

The previous incremental review flagged two issues on agent/DESKTOP.md:

  • <bin> placeholder would be pasted literally (WARNING).
  • exec "$SHELL" did not match cli_wrap's exec "${SHELL:-sh}" fallback (CodeRabbit).

Both were addressed in commit f226788: the example now uses a concrete binary (gum) with a substitute note, and the shell invocation mirrors cli_wrap's ${SHELL:-sh} fallback. No new issues were found on the incremental diff.

Files Reviewed (1 file)
  • agent/DESKTOP.md - 0 issues (2 previously flagged, both resolved)
Previous Review Summary (commit d84756a)

Current summary above is authoritative. Previous snapshots are kept for context only.

Previous review (commit d84756a)

Status: 1 Issue Found | Recommendation: Address before merge

Overview

Severity Count
CRITICAL 0
WARNING 1
SUGGESTION 0
Issue Details (click to expand)

WARNING

File Line Issue
agent/DESKTOP.md 11 <bin> placeholder will be interpreted literally by the assistant reading this doc; needs a concrete or explicitly-marked placeholder.
Files Reviewed (1 file)
  • agent/DESKTOP.md - 1 issue

Fix these issues in Kilo Cloud


Reviewed by minimax-m3 · Input: 20.3K · Output: 1K · Cached: 101.4K

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@agent/DESKTOP.md`:
- Line 11: The example in DESKTOP.md should match the real shell fallback used
by cli_wrap, which relies on exec "${SHELL:-sh}" rather than exec "$SHELL".
Update the launch example referenced by tuiui launch sh -lc so it shows the
fallback behavior correctly and uses the same shell invocation pattern as
cli_wrap, ensuring the docs reflect the interactive shell fallback when SHELL is
unset.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: ef994236-0524-431d-803a-111f0d72f2f1

📥 Commits

Reviewing files that changed from the base of the PR and between ddee9b2 and d84756a.

📒 Files selected for processing (1)
  • agent/DESKTOP.md

Comment thread agent/DESKTOP.md Outdated
@gitar-bot

gitar-bot Bot commented Jul 6, 2026

Copy link
Copy Markdown

Gitar is working

Gitar

…'s shell fallback

Review feedback on the CLI-launch escape-hatch example: the <bin> placeholder
would be interpreted literally if pasted verbatim (sh: 1: <bin>: not found),
and exec "$SHELL" doesn't match cli_wrap's actual exec "${SHELL:-sh}" fallback
for when $SHELL is unset. Swapped in a concrete example (gum) with a
substitute-the-binary note, and fixed the shell invocation to mirror cli_wrap.
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