Claude Code Queue Manager - FIFO auto-switch for multiple Claude Code sessions via tmux
npx claudepluginhub copyx/claude-code-queueClaude Code Queue Manager - auto-switch between multiple Claude Code sessions using FIFO queue
FIFO queue-based auto-switcher for multiple Claude Code sessions via tmux.
Run several Claude Code sessions in a single tmux session. When you submit a prompt in the current window, ccq automatically switches you to the session that has been waiting for input the longest. No more missed idle prompts.
curl -fsSL https://raw.githubusercontent.com/copyx/claude-code-queue/main/install.sh | bash
Prerequisites: tmux must be installed first. See tmux installation guide.
For Claude Code users: Install the plugin first, then run the /ccq:install-cli skill.
Add the marketplace and install the plugin:
/plugin marketplace add copyx/claude-code-queue
/plugin install ccq@claude-code-queue
Then install the CLI binary:
/ccq:install-cli
ccq-darwin-amd64ccq-darwin-arm64ccq-linux-amd64ccq-linux-arm64~/.local/bin/ccqchmod +x ~/.local/bin/ccq~/.local/bin is in your PATHgit clone https://github.com/copyx/claude-code-queue.git
cd claude-code-queue
make build
make install # copies the binary to ~/.local/bin/ccq
Make sure ~/.local/bin is on your PATH.
ccq
Creates a ccq tmux session, launches Claude Code inside it, and attaches your terminal. On first run you will be prompted to choose a tmux prefix key (Ctrl+Space is recommended since Claude Code uses most Ctrl combinations).
From a different terminal (or a different project directory), just run ccq again:
ccq
If a session already exists, ccq adds a new window and starts Claude Code in it. You'll see the new window briefly for initial setup (trust prompt, etc.), then ccq automatically returns you to your previous view.
While you work, ccq tracks every window's state through Claude Code hooks:
If all windows are busy, ccq stays on the current window until one becomes idle.
All keybindings use the tmux prefix you chose during setup.
| Key | Action |
|---|---|
prefix + a | Toggle auto/manual mode |
prefix + n | Next window (tmux built-in) |
prefix + p | Previous window (tmux built-in) |
In manual mode, state tracking still happens but ccq will not switch windows for you. Press prefix + a again to re-enable auto-switching (ccq immediately checks the queue and switches if needed).
ccq is a hook-driven state machine with no long-running daemon.
Notification, UserPromptSubmit, PostToolUse, PostToolUseFailure, SessionEnd).ccq _hook idle, ccq _hook busy, or ccq _hook remove as a short-lived process.@ccq_state, @ccq_idle_since) to track which windows are idle and when they became idle.ccq issues a tmux select-window to the oldest idle window.Configuration is stored at ~/.config/ccq/config (JSON):
{
"prefix": "C-Space"
}
| Key | Description | Default |
|---|---|---|
prefix | tmux prefix key | Set on first run |
MIT
Development marketplace for Superpowers core skills library
Harness-native ECC skills, hooks, rules, MCP conventions, and operator workflows
Open Design — local-first design app exposed to coding agents over MCP. Install once with your agent's plugin command and projects/files/skills are reachable through stdio.