Ship code autonomously with oneshot CLI -- a single command that plans, executes, reviews, and opens a PR. Runs over SSH or locally. Use when the user wants to ship code changes, automate PRs, or run an autonomous coding pipeline with Claude and Codex.
Ship code with a single command. oneshot CLI runs a full autonomous pipeline: plan (Claude) -> execute (Codex) -> review (Codex) -> PR (Claude). Works over SSH to a remote server or locally with --local.
bun install -g oneshot-ship
Run oneshot init to configure SSH host, workspace path, API keys, and model preferences. Config is saved to .
~/.oneshot/config.jsonRepos on the server should be organized as <org>/<repo> under the workspace path:
~/projects/
my-org/my-app/
my-org/my-api/
ANTHROPIC_API_KEY and OPENAI_API_KEY in environmentoneshot <repo> "<task>"
oneshot <repo> <linear-url>
Fetches the ticket as context and updates its status after the PR is created.
oneshot <repo> "<task>" --local
Runs the pipeline directly on the current machine instead of SSH-ing to a server. Requires Claude Code CLI, Codex CLI, and GitHub CLI installed locally.
oneshot <repo> "<task>" --bg
Fire and forget -- runs detached on the server (SSH mode only).
oneshot <repo> --dry-run
Validates the repo exists without running the pipeline.
oneshot <repo> "<task>" --model sonnet
origin/main, auto-detects and installs deps (bun/pnpm/yarn/npm)The worktree is cleaned up after every run.
~/.oneshot/config.json:
{
"host": "[email protected]",
"basePath": "~/projects",
"anthropicApiKey": "sk-ant-...",
"linearApiKey": "lin_api_...",
"claude": { "model": "opus", "timeoutMinutes": 180 },
"codex": { "model": "gpt-5.3-codex", "reasoningEffort": "xhigh", "timeoutMinutes": 180 },
"stepTimeouts": {
"planMinutes": 20,
"executeMinutes": 60,
"reviewMinutes": 20,
"prMinutes": 20
}
}
Only host is required. Everything else has defaults.
| Flag | Short | Description |
|---|---|---|
--model | -m | Override Claude model |
--dry-run | -d | Validate only |
--local | Run locally instead of over SSH | |
--bg | Run in background (SSH mode only) | |
--help | -h | Help |
--version | -v | Version |
CLAUDE.md in any repo root to enforce conventions -- oneshot passes it as context to both Claude and Codexprompts/plan.txt, execute.txt, review.txt, pr.txt to change pipeline behavior--bg for long-running tasks so you can fire and forget