new-claude-tab
v1.0.1
Published
Spawn parallel Claude Code sessions in a new terminal tab with an injected prompt.
Maintainers
Readme
new-claude-tab
Spawn parallel Claude Code sessions in a new terminal tab with an injected prompt. Works with Superset, iTerm2, Terminal.app, Kitty, Warp, and Ghostty.
macOS only.
Install
npm install -g new-claude-tab
new-claude-tab-setupnew-claude-tab-setup runs once to patch your ~/.claude/CLAUDE.md and settings.json. Restart any open Claude Code sessions after.
Usage
From the terminal:
new-claude-tab "implement the login screen"
new-claude-tab "fix the auth bug" ~/Projects/my-appFrom inside a Claude Code session (via Bash tool):
new-claude-tab "implement the login screen" /path/to/projectWhat it does
- Opens a new tab in your terminal
cds to the working directory- Runs
claude "your prompt"— Claude Code starts immediately with your prompt as the first message
The prompt is written to a temp file before being sent, so there is no length limit.
Multi-session orchestration
After running new-claude-tab-setup, Claude Code will proactively suggest splitting large multi-task requests into parallel sessions.
Example: tell Claude "implement the auth flow: login, signup, and password reset" and it will propose spawning three independent tabs instead of doing them sequentially.
You review the task breakdown, approve it, and Claude spawns the sessions.
Supported terminals
| Terminal | Method |
|---|---|
| Superset | AppleScript |
| iTerm2 | Native iTerm2 AppleScript API |
| Terminal.app | System Events (Cmd+T) |
| Kitty | kitty @ launch (requires allow_remote_control yes in kitty.conf) |
| Warp | System Events (Cmd+T) |
| Ghostty | System Events (Cmd+T) |
Permissions
new-claude-tab-setup adds Bash(new-claude-tab:*) to your Claude Code settings.json so Claude can spawn tabs without a permission prompt each time.
How it works
AppleScript opens a new tab in your terminal and types bash /tmp/claude-launch-XXXXXX. That temp script contains the cd and claude "prompt" call, then deletes itself. The temp file approach avoids keystroke length limits and shell escaping issues with complex prompts.
