Skip to content

HouseinIsProgramming/claude-code-commander

Repository files navigation

Claude Code Commander

Singleton daemon managing multiple Claude Code PTY sessions with CLI + web dashboard.

Installation

bun install
bun link  # Makes 'ccc' command available globally

Running the Daemon

The daemon runs on port 9500 and manages all Claude Code sessions.

# Development (with hot reload)
bun dev

# Production
bun start

The daemon auto-starts when using CLI commands if not already running.

Daemon endpoints:

  • HTTP/WebSocket: http://localhost:9500
  • Web Dashboard: http://localhost:9500
  • WebSocket: ws://localhost:9500/ws
  • IPC Socket: ~/.claude-code-commander/daemon.sock

Files created:

  • ~/.claude-code-commander/daemon.pid - PID file (ensures singleton)
  • ~/.claude-code-commander/sessions.json - Session persistence

CLI Usage

ccc                  # Spawn new session and attach
ccc spawn            # Spawn new session (background)
ccc spawn --name foo # Spawn named session
ccc attach <id>      # Attach to existing session
ccc status           # List all sessions
ccc kill <id>        # Kill session
ccc open             # Open web dashboard in browser

Detach from session: Ctrl+B d (tmux-style)

Web Dashboard

Open http://localhost:9500 in your browser or run ccc open.

Features:

  • View all active sessions
  • Full terminal emulation (xterm.js)
  • Real-time status indicators
  • Create/kill sessions from UI

Architecture

┌─────────────────────────────────────────────────┐
│            Daemon (Port 9500)                   │
│                                                 │
│  IPC Server ←──── CLI (ccc)                    │
│  (Unix socket)                                  │
│                                                 │
│  HTTP + WebSocket ←──── Browser Dashboard      │
│                                                 │
│  SessionManager (singleton)                     │
│    └── ClaudeSession[] (Bun.spawn PTY)         │
└─────────────────────────────────────────────────┘

Development

bun dev      # Start daemon with HMR
bun test     # Run tests
bun run cli  # Run CLI directly (without bun link)

Requirements

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors