Skip to content

Enhancement: Tmux integration for /parallel-work #37

Description

@evansenter

Summary

Enhance /parallel-work start to optionally auto-create a tmux pane or window for the new worktree session.

Current Behavior

When running /parallel-work start <branch>, the user must manually:

  1. Open a new terminal
  2. cd to the worktree directory
  3. Run claude with the context prompt

Proposed Behavior

Add tmux integration that automatically:

  1. Creates a new tmux pane or window
  2. Changes to the worktree directory
  3. Starts a claude session with the context

Implementation Ideas

Option 1: New Subcommand

/parallel-work start <branch> --tmux-pane    # Split current window
/parallel-work start <branch> --tmux-window  # New window in session

Option 2: AskUserQuestion Choice

After creating the worktree, ask:

  • "Open in new tmux pane (Recommended)"
  • "Open in new tmux window"
  • "Manual - I'll open it myself"

Technical Considerations

  • Detect if running inside tmux ($TMUX env var)
  • Use tmux split-window -c <worktree-path> for pane
  • Use tmux new-window -c <worktree-path> for window
  • Send the claude startup command: tmux send-keys "claude 'See .parallel-context.md'" Enter

Open Questions

  1. Should this be opt-in (flag) or default behavior when in tmux?
  2. Preferred default: pane or window?
  3. Should we support non-tmux terminals (iTerm2 tabs, Terminal.app)?

Related

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions