drive
Skill2 starsChanged 8 months agoMITView on GitHub
Terminal automation CLI for AI agents. Use drive to create tmux sessions, execute commands, send keystrokes, read output, poll for patterns, run commands in parallel across sessions, and manage processes. Always use --json for structured output.
6 other projects use a version of this.
Adopted by
Most recently taken up by
- sidmanale643/pekka-bottheir own version, first seen Nov 8, 2026
- disler/mac-mini-agentword for word, first seen Oct 8, 2026
- HaipingShi/coderailtheir own version, first seen Jul 8, 2026
- hsigstad/research-kittheir own version, first seen Jul 5, 2026
- permit0-ai/permit0their own version, first seen Jun 22, 2026
- callmeradical/skillstheir own version, first seen Jun 11, 2026
Other versions6 projects use a version of this.
Word for word · 1
- disler/mac-mini-agent★ 272100% same
Edited · 0
None found.
Wrote their own version · 5
- permit0-ai/permit0★ 185same name
- HaipingShi/coderail★ 8same name
- sidmanale643/pekka-bot★ 2same name
- callmeradical/skills★ 0same name
- hsigstad/research-kit★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository239 other files it gives its agents.
- claude-code-docs/agents.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- claude-code-docs/llms.txtllms.txt
- agent-native-architectureSkill
- claude-apiSkill
- embedding-strategiesSkill
- fal-ai-mediaSkill
- gemini-imagegenSkill
- hybrid-search-implementationSkill
- langchain-architectureSkill
- llm-evaluationSkill
- ml-pipeline-workflowSkill
- prompt-engineering-patternsSkill
- rag-implementationSkill
- similarity-search-patternsSkill
- vector-index-tuningSkill
- api-design-principlesSkill
- api-designSkill
- architecture-patternsSkill
- cqrs-implementationSkill
- event-store-designSkill
- fastapi-templatesSkill
- microservices-patternsSkill
- openapi-spec-generationSkill
- projection-patternsSkill
- saga-orchestrationSkill
- api-conventionsSkill
- andrew-kane-gem-writerSkill
- angular-migrationSkill
- auth-implementation-patternsSkill
- backend-patternsSkill
- bazel-build-optimizationSkill
- coding-standardsSkill
- database-migrationSkill
- debugging-strategiesSkill
- dependency-upgradeSkill
- dhh-rails-styleSkill
- dotnet-backend-patternsSkill
- dspy-rubySkill
- error-handling-patternsSkill
- monorepo-managementSkill
- nodejs-backend-patternsSkill
- nx-workspace-patternsSkill
- react-modernizationSkill
- temporal-python-testingSkill
- turborepo-cachingSkill
- workflow-orchestration-patternsSkill
- defi-protocol-templatesSkill
- nft-standardsSkill
- solidity-securitySkill
- web3-testingSkill
- backtesting-frameworksSkill
- billing-automationSkill
- competitive-landscapeSkill
- data-storytellingSkill
- employment-contract-templatesSkill
- investor-materialsSkill
- investor-outreachSkill
- kpi-dashboard-designSkill
- market-sizing-analysisSkill
- The first 60 shown.
The file
Files
Drive — Terminal Automation via tmux
Run from: cd apps/drive && uv run python main.py <command>
Drive gives you full programmatic control over tmux sessions — creating terminals, running commands, reading output, and orchestrating parallel workloads.
Commands
session — Manage tmux sessions
drive session create agent-1 --json # Opens a Terminal window (headed — default)
drive session create agent-1 --window build --json # Named window, headed
drive session create agent-1 --detach --json # Headless (no Terminal window)
drive session list --json # List all sessions
drive session kill agent-1 --json # Kill a sessionDefault is headed — a new Terminal.app window opens attached to the session so you can watch live. Only use --detach when you explicitly need a headless session.
run — Execute command and wait for completion
Uses sentinel protocol (__DONE_<token>:<exit_code>) for reliable completion detection.
drive run agent-1 "npm test" --json # Run and wait
drive run agent-1 "make build" --timeout 120 --json # Custom timeout
drive run agent-1 "ls" --pane 1 --json # Target specific paneReturns: exit code, captured output between sentinels.
send — Raw keystrokes (no completion waiting)
For interactive tools (vim, ipython, etc.) where sentinel detection would interfere.
drive send agent-1 "vim file.txt" --json # Send command
drive send agent-1 ":wq" --json # Send vim command
drive send agent-1 "y" --no-enter --json # Send without Enterlogs — Capture pane output
drive logs agent-1 --json # Current pane content
drive logs agent-1 --lines 500 --json # Last 500 lines of scrollback
drive logs agent-1 --pane 1 --json # Specific panepoll — Wait for pattern in output
drive poll agent-1 --until "BUILD SUCCESS" --json # Wait for pattern
drive poll agent-1 --until "ready" --timeout 60 --json # With timeout
drive poll agent-1 --until "error|success" --interval 2.0 --json # Custom intervalPattern is a regex. Returns matched text and full pane content.
fanout — Parallel execution
drive fanout "npm test" --targets agent-1,agent-2,agent-3 --json # Same command, multiple sessions
drive fanout "git pull" --targets a1,a2,a3 --timeout 30 --json # With timeoutRuns command in all target sessions concurrently using ThreadPoolExecutor. Returns ordered results.
Key Patterns
- Create sessions first —
drive session createbefore running commands (headed by default — opens a Terminal window) - Use
runfor commands that complete — It waits and gives you exit code + output - Use
sendfor interactive tools — vim, ipython, anything that doesn't "finish" - Use
pollto wait for async events — Watch for build completion, server startup, etc. - Use
logsto inspect — Check what happened in a pane - Use
fanoutfor parallel work — Run same command across multiple sessions - Use
procfor process management — List, kill, and inspect processes instead of raw ps/kill - Use
--jsonalways — Structured output for reliable parsing - Write all files to /tmp — Any JSON, logs, or other files you generate must go to
/tmp/. Never write output files into the project directory.
proc — Process management
List, kill, inspect, and monitor processes. The agent's replacement for Activity Monitor.
drive proc list --json # All user processes
drive proc list --name claude --json # Filter by name
drive proc list --session job-abc123 --json # Processes in a tmux session
drive proc list --parent 12345 --json # Children of a PID
drive proc list --cwd /path/to/project --json # Processes running from a directory
drive proc kill 12345 --json # Kill by PID (SIGTERM → wait → SIGKILL)
drive proc kill --name "claude" --json # Kill all matching name
drive proc kill 12345 --tree --json # Kill PID and all children
drive proc kill 12345 --force --json # Force kill (SIGKILL, no grace period)
drive proc kill 12345 --signal 9 --json # Same as --force
drive proc tree 12345 --json # Show process tree from PID
drive proc top --session job-abc123 --json # Resource snapshot for session
drive proc top --pid 12345,12346 --json # Resource snapshot for specific PIDsEach process includes cwd (working directory) in its JSON output — use this to identify processes spawned from a specific project or directory.
Kill uses a two-step pattern: sends the signal (default SIGTERM), waits up to 5 seconds for graceful exit, then SIGKILL if still alive. Use --tree to kill a process and all its children (critical for Claude Code which spawns node subprocesses).
Process cleanup pattern
During cleanup, cd back to your original working directory and use proc list to find processes you started that you don't need running anymore. If the task specified they should keep running, leave them alone.
1. drive proc list --session job-abc123 --json → see what's running
2. drive proc kill <pid> --tree --json → kill it and children
3. drive proc list --name <name> --json → verify nothing survivedSentinel Protocol
Drive wraps commands with markers: echo "__START_<token>" ; <cmd> ; echo "__DONE_<token>:$?"
This gives:
- Reliable completion detection (no guessing)
- Accurate exit code capture
- Clean output extraction (only content between markers)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

