Milestone 3: command planning and exec handoff #3

Closed
opened 2026-05-26 19:16:09 +00:00 by KofTwentyTwo · 0 comments
KofTwentyTwo commented 2026-05-26 19:16:09 +00:00 (Migrated from github.com)

Goal

Implement the command selection and process handoff layer that turns a chosen host and session action into the final tmux or ssh -t ... tmux exec target.

Scope

  • Implement internal/exec command planning for local and remote attach/new-session flows per docs/DESIGN.md §8.2 and §9.3.
  • Use syscall.Exec for the final handoff, with an injectable boundary so tests can verify argv without replacing the test process.
  • Implement new-session name validation per §8.4.
  • Update state immediately before exec so lastAttached reflects the chosen host per §7.2.
  • Surface exec failures as limen: exec failed: <error> and exit 127.
  • Add unit tests for local attach, local new, remote attach, remote new, named session validation, state update timing, and exec failure formatting.

Out of scope

  • Bubble Tea or Lip Gloss.
  • Host/session picker rendering.
  • Automated tests that actually exec tmux or ssh.

Acceptance criteria

  • Command planning is deterministic and fully unit-tested.
  • Logic packages remain UI-agnostic.
  • go test -race ./... passes.
  • go vet ./... passes.
  • CI is green.
## Goal Implement the command selection and process handoff layer that turns a chosen host and session action into the final `tmux` or `ssh -t ... tmux` exec target. ## Scope - Implement `internal/exec` command planning for local and remote attach/new-session flows per `docs/DESIGN.md` §8.2 and §9.3. - Use `syscall.Exec` for the final handoff, with an injectable boundary so tests can verify argv without replacing the test process. - Implement new-session name validation per §8.4. - Update state immediately before exec so `lastAttached` reflects the chosen host per §7.2. - Surface exec failures as `limen: exec failed: <error>` and exit 127. - Add unit tests for local attach, local new, remote attach, remote new, named session validation, state update timing, and exec failure formatting. ## Out of scope - Bubble Tea or Lip Gloss. - Host/session picker rendering. - Automated tests that actually exec tmux or ssh. ## Acceptance criteria - Command planning is deterministic and fully unit-tested. - Logic packages remain UI-agnostic. - `go test -race ./...` passes. - `go vet ./...` passes. - CI is green.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: KofTwentyTwo/limen#3