1password
Set up and use 1Password CLI for sign-in, desktop integration, and reading or injecting secrets.
Run Claude Code (Anthropic) from this host via the `claude` CLI (Agent SDK) in headless mode (`-p`) for codebase analysis, refactors, test fixing, and structured output. Use when the user asks to use Claude Code, run `claude -p`, use Plan Mode, auto-approve tools with
Claude Code
$ npx -y skills add win4r/claude-code-clawdbot-skill --skill claude-code-clawdbot-skill --agent claude-code
Codex
$ npx skills add win4r/claude-code-clawdbot-skill --skill claude-code-clawdbot-skill -a codex -y
Cursor
$ npx skills add win4r/claude-code-clawdbot-skill --skill claude-code-clawdbot-skill -a cursor -y
Gemini CLI
$ npx skills add win4r/claude-code-clawdbot-skill --skill claude-code-clawdbot-skill -a gemini-cli -y
GitHub Copilot
$ npx skills add win4r/claude-code-clawdbot-skill --skill claude-code-clawdbot-skill -a github-copilot -y
OpenCode
$ npx skills add win4r/claude-code-clawdbot-skill --skill claude-code-clawdbot-skill -a opencode -y
Windsurf
$ npx skills add win4r/claude-code-clawdbot-skill --skill claude-code-clawdbot-skill -a windsurf -y
name: claude-code-clawdbot description: "Run Claude Code (Anthropic) from this host via the `claude` CLI (Agent SDK) in headless mode (`-p`) for codebase analysis, refactors, test fixing, and structured output. Use when the user asks to use Claude Code, run `claude -p`, use Plan Mode, auto-approve tools with --allowedTools, generate JSON output, or integrate Claude Code into Clawdbot workflows/cron."
Use the locally installed **Claude Code** CLI reliably.
This skill supports two execution styles:
This skill is for **driving the Claude Code CLI**, not the Claude API directly.
Verify installation:
claude --version
Run a minimal headless prompt (prints a single response):
./scripts/claude_code_run.py -p "Return only the single word OK."
cd /path/to/repo /home/ubuntu/clawd/skills/claude-code-clawdbot/scripts/claude_code_run.py \ -p "Summarize this project and point me to the key modules." \ --permission-mode plan
Claude Code supports tool allowlists via `--allowedTools`. Example: allow read/edit + bash:
./scripts/claude_code_run.py \ -p "Run the test suite and fix any failures." \ --allowedTools "Bash,Read,Edit"
./scripts/claude_code_run.py \ -p "Summarize this repo in 5 bullets." \ --output-format json
./scripts/claude_code_run.py \ -p "Review the staged diff for security issues." \ --append-system-prompt "You are a security engineer. Be strict." \ --allowedTools "Bash(git diff *),Bash(git status *),Read"
> "Update your CLAUDE.md so you don't make that mistake again."
This ensures Claude Code records lessons learned and avoids repeating the same errors.
Claude performs dramatically better when it can verify its work. Make verification explicit in the prompt, e.g.:
For multi-step work, start in plan mode to do safe, read-only analysis:
./scripts/claude_code_run.py -p "Analyze and propose a plan" --permission-mode plan
Then switch to execution (`acceptEdits`) once the plan is approved.
Long, mixed-topic sessions degrade quality.
Claude checkpoints before changes. If an approach is wrong, use `/rewind` (or Esc Esc) to restore:
This enables “try something risky → rewind if wrong” loops.
Best practice is a concise CLAUDE.md (global or per-project) for:
Overlong CLAUDE.md files get ignored.
In `.claude/settings.json` / `~/.claude/settings.json`, rules match in order: **deny first**, then ask, then allow. Use deny rules to block secrets (e.g. `.env`, `secrets/**`).
Each Bash tool call runs in a fresh shell; `export FOO=bar` won’t persist. If you need persistent env setup, set (before starting Claude Code):
export CLAUDE_ENV_FILE=/path/to/env-setup.sh
Claude will source it before each Bash command.
Use hooks to enforce deterministic actions (format-on-edit, block writes to sensitive dirs, etc.) when you need guarantees.
Subagents can read many files without polluting the main context. Use them for broad codebase research or post-implementation review.
Examples:
cat build-error.txt | claude -p "Explain root cause" claude -p "List endpoints" --output-format json
This is ideal for CI and automation.
If your prompt contains lines starting with `/` (slash commands), the wrapper defaults to **auto → interactive**.
Example:
./scripts/claude_code_run.py \ --mode auto \ --permission-mode acceptEdits \ --allowedTools "Bash,Read,Edit,Write" \ -p $'/speckit.constitution ...\n/speckit.specify ...\n/speckit.plan ...\n/speckit.tasks\n/speckit.implement'
It will print tmux attach/capture commands so you can monitor progress.
When you want Claude Code to drive **Spec Kit** end-to-end via `/speckit.*`, do **not** use headless `-p` for the whole flow. Use **interactive tmux mode** because:
A Clawdbot skill to run Claude Code (Anthropic) on the host via the claude CLI (Agent SDK). This repo provides: SKILL.md: how Clawdbot should use this skill scripts/claude_code_run.py: a small wrapper that runs claude -p ...
Set up and use 1Password CLI for sign-in, desktop integration, and reading or injecting secrets.
Use your assigned AgentMail inbox to read email tasks, explicitly send or reply, and check delivery. Provided automatically by…
Drives the GUI of a visible local app window through `orca computer`: accessibility tree, clicks, typing, menus, dialogs, and…
Create a new Architecture Decision Record with sequential numbering and AgentDB registration