| type | skill |
| name | bapxphp-cli |
| description | Use bapXphp CLI for ALL file/content/db operations. Never use raw shell/edit/write/find/grep tools directly. |
bapXphp CLI
All project operations go through bapXphp. This ensures every operation is auditable, logged, and consistent.
Generic File Operations
| Operation | CLI Command |
|---|
| Read file | bapXphp read file <path> |
| Write file | bapXphp write file <path> (pipe stdin) |
| Edit file | bapXphp edit <path> <search> <replace> |
| Search code | bapXphp grep <pattern> [path] |
| Find files | bapXphp find <glob-pattern> |
| Run command | bapXphp run <command...> |
| List dir | bapXphp run ls <path> |
Content CRUD
bapXphp read blog
bapXphp read blog <slug>
bapXphp write blog [slug]
bapXphp read docs [slug]
bapXphp write docs [slug]
bapXphp read product
bapXphp read product <slug>
bapXphp write product [slug]
Database
bapXphp db query products --limit 5
bapXphp db find orders ord_123
bapXphp db raw "SELECT * FROM ..."
bapXphp db init
bapXphp db sync
Project Management
bapXphp test
bapXphp update
bapXphp ci
bapXphp check
bapXphp serve
bapXphp map:gen
bapXphp docsmap
bapXphp codemap
bapXphp schema list
bapXphp hooks install
bapXphp hooks status
bapXphp tui
bapXphp help
Run the smallest useful validation for the change:
```bash
bapXphp lint path/to/changed.php
bapXphp update
bapXphp ci
Telemetry & Ops
Handoffs and telemetry live under .agents/:
bapXphp handoff next <issue>
bapXphp handoff validate <file>
Cycle data is tracked in .agents/ops/telemetry.json.
Use plain git for branches, commits, fetch, pull, and push. GitHub Actions
and the GitHub web interface own issue/PR/handoff conversations. The hosted
server does not require gh.
Attachments
When a coding agent attaches screenshots, images, or files, they go into .agents/temp/. This is the standard inbox for all user-provided attachments in this repo.
bapXphp run ls .agents/temp/
bapXphp read file .agents/temp/<file>
Browser Agent (headless browser automation)
bapXphp browser-agent open <url>
bapXphp browser-agent click <selector>
bapXphp browser-agent fill <selector> <value>
bapXphp browser-agent submit [selector]
bapXphp browser-agent snapshot
bapXphp browser-agent smoke <url>
bapXphp browser-agent screenshot [file]
bapXphp browser-agent config set <k> <v>
bapXphp browser-agent log
bapXphp browser-agent count <tag>
bapXphp browser-agent close
bapXphp browser-agent --pw <command>
Missing Commands
If a required operation is missing or unsafe, enhance the nearest existing bapXphp command before performing the operation. Never use raw bash/write/edit/find tools for operations that have a bapXphp equivalent.