coding-agent
What it does
It guides an AI agent through starting a coding tool such as Codex, Claude Code, or OpenCode to build a feature, review a pull request, or do a large refactor in the background. It is for people who want to hand off bigger programming tasks.
When to use it
- ✓When you want a larger feature built in the background while you do other work.
- ✓When you need a pull request reviewed or a big refactor done by a coding tool.
- ✓When you want an issue turned into a pull request by a coding worker.
Skill link
https://github.com/openclaw/openclaw/blob/main/skills/coding-agent/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agent’s skills folder.
Example of what to ask your AI
“Have Codex build the new export feature in a separate copy of the project and tell me when it is finished.”
5 new skills a week. 1 minute to read.
How it works
The skill starts the chosen coding tool in a background process, working in an isolated copy of the project. It watches progress and reports back when the worker finishes or fails.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Coding Agent
Use for background feature builds, PR reviews, large refactors, and issue-to-PR loops. Do not use for simple edits, read-only lookup, ACP thread-bound work, or any run inside ~/.openclaw, $OPENCLAW_STATE_DIR, or active OpenClaw state dirs.
Hard rules
- Always launch with
background:true. - Codex and OpenCode: use
pty:true. - Codex: never inherit ambient
CODEX_HOMEor the default~/.codex. Use a separately authenticated coding-agent home and scope it to each Codex command. - Claude Code: no PTY; use
claude --permission-mode bypassPermissions --print. - Capture a real notification route before spawning.
- Worker must send completion/failure via
openclaw message send. - Do not rely on heartbeat, system events, or notify-on-exit.
- Monitor with
process; do not kill slow workers without cause. - If user asked for a specific agent, use that agent.
- If worker fails/hangs, respawn or ask; do not silently hand-code instead.
- Never checkout branches or run background coding agents in
~/Projects/openclaw; use an isolated checkout. - Classify the source ref as trusted or untrusted before any checkout or worktree creation. Never materialize a contributor-controlled ref outside the repository's approved untrusted-PR sandbox/review workflow, and never launch a permission-bypassed worker in it.
- For tasks that modify a Git-backed project, prepare and verify the Git worktree before launch, then include the exact Git preparation block below in the worker prompt.
Mandatory Git preparation
Before launching Codex, Claude Code, or OpenCode for work that modifies a Git-backed project:
- Establish the intended target repository, then select its canonical remote. Prefer
upstreamwhen it exists and matches that target; otherwise verifyorigin. Resolve the selected remote's default branch dynamically. Determine the target base from an explicit task branch or authoritative existing-PR metadata; for other shared branches, prove the configured/tracked base or ask. Use the canonical default only for new work with no other specified base. Stop if the repository, remote, or target base cannot be proven. - Classify the source ref as trusted or untrusted before any checkout or worktree creation. For contributor-controlled refs, use the repository's approved untrusted-PR sandbox/review workflow, which must own ref materialization inside the sandbox, or stop. The remaining steps and launch forms are for trusted refs only.
- For trusted new work, run
git fetch --prune <canonical>immediately before creating a new isolated worktree and branch from<canonical>/<targetBaseBranch>. - For trusted new work, verify the worktree's initial
HEADequals the fetched target-base SHA. Record the canonical remote, canonical default branch, target base branch, base SHA, worktree path, and branch. - For a trusted existing PR or shared branch, fetch the canonical target base and source branch immediately before creating an isolated worktree from the fetched source branch. Record that source ref and starting SHA, report its divergence from the refreshed target base, and do not automatically rebase, merge, reset, force-push, or otherwise rewrite shared history.
- Launch the worker in the isolated worktree, never the primary checkout. For OpenClaw, the primary checkout under
~/Projects/openclawremains forbidden.
For tasks that modify a Git-backed project, append this block to the worker prompt with real values:
Git preparation (mandatory before edits):
- canonical remote: <canonicalRemote>
- canonical default branch: <canonicalDefaultBranch>
- target base branch: <targetBaseBranch>
- fetched target base SHA: <targetBaseSha>
- preparation mode: <new work | existing PR/shared branch>
- checkout trust: trusted
- prepared source ref: <canonicalRemote/targetBaseBranch | fetched trusted source ref>
- prepared start SHA: <preparedStartSha>
- isolated worktree: <worktreePath>
- working branch: <branch>
- preparation receipt: <new work: `git fetch --prune <canonicalRemote>` ran immediately before creation from `<canonicalRemote>/<targetBaseBranch>` | existing branch: the canonical target base and trusted source ref were fetched immediately before the worktree was created from `<preparedSourceRef>` at `<preparedStartSha>`>
Before editing, verify the current directory is the isolated worktree and its initial HEAD equals <preparedStartSha>. For new work, that SHA must equal <targetBaseSha>. Never edit the
FAQ
Will it edit my main project directly?
No. The work is done in an isolated checkout, not directly in your main project folder.
Does it handle simple edits too?
No. Simple edits and read-only code lookups are better done directly, so this skill is for larger jobs.
What happens if the worker gets stuck?
The skill monitors the worker and can restart it or ask you, rather than quietly doing the work by hand.
Details
Original description by the author
Delegate coding work to Codex, Claude Code, or OpenCode as background workers; not simple edits or read-only code lookup.
repo: openclaw/openclaw
Popularity
- GitHub stars
- 394k
- Ranking position
- #49
- License
- MIT
- Updated
- 11/2/2026
Comments
- …
More skills from this repository
discord-user-post
394kLets your agent post a message you have approved to Discord as you, through the Discord desktop app, after confirming the exact channel.
discrawl
394kLets your agent search and summarize a saved local archive of Discord messages, check how fresh it is, and read direct messages.
gitcrawl
394kLets your agent search a saved archive of GitHub issues and pull requests, group duplicates, and check their current status on GitHub.
graincrawl
394kLets your agent search your saved Granola meeting notes and transcripts, check how fresh they are, and count them over a period.
Similar skills
executing-plans
311kHelps your agent carry out a written implementation plan step by step in the current session, testing each step before moving on.
finishing-a-development-branch
311kHelps your agent wrap up finished code by running the tests, then offering clear options to merge, open a pull request, or keep the branch.
receiving-code-review
311kHelps your agent weigh code review feedback carefully, checking each point against the code before changing anything.