Skip to content

Add Pi TUI daemon launcher#126

Merged
glittercowboy merged 1 commit intomainfrom
codex/pi-tui-launcher
May 1, 2026
Merged

Add Pi TUI daemon launcher#126
glittercowboy merged 1 commit intomainfrom
codex/pi-tui-launcher

Conversation

@glittercowboy
Copy link
Copy Markdown
Contributor

@glittercowboy glittercowboy commented May 1, 2026

Summary

  • Adds gsd-cloud pi-tui for launching Pi TUI with the daemon Pi extension, provider registry, model cycling list, session path, runtime prompt, and task-scoped tool environment.
  • Adds scripts/pi-tui.sh as the local entrypoint for running the launcher from a daemon checkout.
  • Exposes shared Pi argument and environment builders from internal/pi so the TUI launcher uses the same daemon configuration path.

Verification

  • go test ./...
  • go build ./...
  • bash -n scripts/pi-tui.sh
  • scripts/pi-tui.sh --help
  • scripts/pi-tui.sh --print-command --cwd . --session-id smoke --provider codex-appserver --model gpt-5.5 "say hi"

Summary by CodeRabbit

  • New Features

    • Added pi-tui CLI command supporting configurable working directory, provider/model selection, session management, custom instructions, skill files, agent tools, and browser grant settings.
  • Chores

    • Added shell script entrypoint for the pi-tui command.
    • Exposed internal helper functions for command argument and environment processing.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 1, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 120507b4-35d3-47bf-94e8-38bb48b00a00

📥 Commits

Reviewing files that changed from the base of the PR and between 0cd28a2 and 43690bc.

📒 Files selected for processing (3)
  • cmd/pi_tui.go
  • internal/pi/executor.go
  • scripts/pi-tui.sh

📝 Walkthrough

Walkthrough

This pull request introduces a new pi-tui CLI command that orchestrates the Pi TUI process startup, handling extension resolution, flag parsing, custom instructions concatenation, session file management, optional agent-tools backend initialization, and process lifecycle management. Two utility functions in the executor package are also exposed for external use.

Changes

Cohort / File(s) Summary
Pi TUI Command
cmd/pi_tui.go, scripts/pi-tui.sh
New Pi TUI command implementation with comprehensive flag parsing (cwd, provider, models, session settings, custom instructions, skill files, agent tools), extension path resolution with fallback chain, session file determination under ~/.gsd-cloud/pi-sessions/, optional agent-terminal backend startup, and process execution with context-aware termination handling.
Executor Helpers
internal/pi/executor.go
Exports two new public functions, ProcessArgs and ProcessEnv, that wrap existing internal argument and environment variable construction logic for Pi daemon configuration.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~30 minutes

Possibly related PRs

Poem

🐰 A terminal for Pi, now we can run,
With extensions resolved and custom instructions spun,
Agent tools dancing, sessions secure,
The rabbit hops forward, of changes quite sure! ✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 8.70% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The pull request title 'Add Pi TUI daemon launcher' clearly and accurately summarizes the main change—introducing a new CLI command and supporting infrastructure to launch the Pi TUI via the daemon.
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.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/pi-tui-launcher

Review rate limit: 9/10 reviews remaining, refill in 6 minutes.

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

@glittercowboy glittercowboy merged commit 78f5e21 into main May 1, 2026
2 checks passed
@glittercowboy glittercowboy deleted the codex/pi-tui-launcher branch May 1, 2026 03:52
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