Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/lykhoyda/rn-dev-agent/check-envgit clone --depth 1 https://github.com/Lykhoyda/rn-dev-agentWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00021 | $0.01231 |
| Opus 5 | $0.00010 | $0.00616 |
| Sonnet 5 | $0.00004 | $0.00246 |
| Haiku 4.5 | $0.00002 | $0.00123 |
Grade A, and why
check-env scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 78 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Run rn_session(action="status"), then passive cdp_status, and report
environment readiness. Use device_list only as diagnostic inventory; never
turn an ambient port or the first available device into authority.
Before navigation, run the cross-platform foreground-surface preflight on the
authority-bound device. This preflight belongs to the attaching rn-dev-agent
session; launch or foreground helpers, including rn-qa, stop before native-UI
dismissal. Connect the exact signed target when CDP is not already connected,
capture one fresh device_snapshot, classify the foreground, and invoke exactly
one matching remedy:
When the snapshot returns meta.foregroundSurface and a structured
meta.recommendation, invoke exactly its tool with its arguments; the first
supported point-of-need recommendation is
expo_dev_menu -> cdp_dev_settings({ action: "hideDevMenu" }).
| Foreground surface | Single remedy |
|---|---|
| Expo Developer Menu sheet | cdp_dev_settings(action="hideDevMenu") |
Expo Development servers picker |
cdp_dismiss_dev_client_picker |
| Expo first-run tutorial | Replay the compatible owned locked/helper action through cdp_run_action |
| React Native core dev menu | Stop: no authority-approved close remedy exists |
| App | None |
Capture a second fresh snapshot after a remedy and require the app surface
before navigation. An ordinary React Native core dev menu is a truthful stop;
disableDevMenu only disables future shake opening and does not close a visible
menu. DEV_MENU_HIDE_UNVERIFIED means the close call was sent but
the surface is still occluded or could not be proven clean: classify again and
do not fall back to coordinates or BACK. DEV_MENU_HIDE_FAILED means no close
call was sent and also requires a fresh classification. Keep USB transport as
a separate readiness axis; never classify it as a menu state. System dialogs
and app-owned native overlays have separate owners and never inherit the Expo
menu remedy. Do not use coordinates, screen-wide label search, raw shell UI, or
a generic native-window action as a fallback.
Check each subsystem and report status as a table:
| Subsystem | What to check | Source |
|---|---|---|
| Source declaration | Git app roots declare nothing. Before the supervisor starts for a non-Git app root, check RN_DEV_AGENT_DECLARED_ROOT and RN_DEV_AGENT_DECLARED_MANIFESTS against the session-authority contract |
git rev-parse --show-toplevel, then the two variables in the supervisor environment |
| Session | Ready state, worktree, app, platform, exact device, Metro binding, and migration readiness | rn_session(action="status") |
| Metro | Allocated and bound port for this session | rn_session, then cdp_status → metro |
| CDP | Exact authority-bound target connected? | rn_session, then cdp_status → cdp |
| Device inventory | Intended UUID/serial still present? | device_list, compared with the session binding |
If issues are found, suggest the appropriate fix:
| Status | Fix |
|---|---|
NON_GIT_MANIFEST_REQUIRED |
Report this before setup or build, name the missing RN_DEV_AGENT_DECLARED_ROOT or RN_DEV_AGENT_DECLARED_MANIFESTS declaration, and point to the session-authority contract |
Session state: blocked |
Another session owns this worktree. Report recoveryRequirement.nextAction verbatim (plus startupCleanupBlocked when present) and stop — do not run setup, do not bind a device, do not pick another booted device. See using-rn-dev-agent § "Session ownership recovery" |
Session missing or genuinely unbound (not blocked) |
Run setup, review/apply the integration preview, and bind the intended device and app |
| Metro not found | Use literal pnpm ios or pnpm android through the confirmed integration |
| No Hermes target | Open the bound app, then call cdp_connect for the exact signed target |
| CDP code 1006 | Close React Native DevTools, Flipper, Chrome DevTools |
cdp_component_tree reports RedBox |
Run /rn-dev-agent:debug-screen |
| Narrow gated CDP read times out | Check for a blocked JS thread, then use cdp_reload |
HELPERS_NOT_INJECTED |
Read bounded meta.helperHealth; use a __DEV__ Hermes build and retry through the gated tool after reload |
| No devices in device_list | Boot a simulator: xcrun simctl boot "iPhone 16" or start an emulator |
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 78 lines · 21 tokens per session scan A 09f19c8913c7
check-env is a command published in the GitHub repository Lykhoyda/rn-dev-agent (11 stars, last pushed yesterday), licensed MIT. It adds 21 tokens to every session and 1,231 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
dashboard-flow-auto
Toggle autonomous mode for a session's flow. Usage /dashboard:flow-auto.
dashboard-flow-abort
Abort the running flow on a session. Usage /dashboard:flow-abort.
dashboard-git-branches
List git branches for the current dir (current marked ). Runs locally, no LLM.
brainstorm
Command dispatcher for brainstorm.
discover
Command dispatcher for discover.
propose
Command dispatcher for propose.