agentleFS
ndisisndndisisnd/msg/.claude/skills/emulate/SKILL.md

emulate

Skill6 starsChanged 4 months agoMITView on GitHub

Runs this repo's app on a local simulator or emulator and opens the window on the user's desktop. Use it when the user says "run the app", "open the simulator", "launch the emulator", "boot the iOS sim", "start Expo", "see it running", "show me the app", or invokes `/emulate`. Takes the branch the user is standing on, clears the stale build processes from the last attempt, and launches. `--ios` / `--adr` / `--expo` pick the lane; with no flag the platform is read from `devkit/PLATFORMS.md`. `--device` pins the simulator or AVD, `--dry-run` shows what would happen and touches nothing. Writes nothing to the repo — no commits, no branches, no PRs.

2 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions2 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 2

    1. vercel-labs/emulate★ 2ksame name
    2. jonmumm/skills★ 2same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository9 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 0 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Every mode runs the same protocol — refs/protocol.md.

    line 32
  2. Very specific:

    Every run ends with the closing message per ../shared/refs/closing-message.md, after the launch banner.

    line 82

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

emulate

The harness's local run lane. /pre-merge runs the checks and /merge deploys to a remote target; neither one puts a live app in front of a human on their own machine. That is this skill's whole job.

/emulate is a leaf: nothing invokes it and it invokes nothing. It has no place in the intake → plan-pm → plan-em → eng → pre-merge → merge spine and never blocks it. Run it whenever you want to look at the app.

Dispatch

Every mode runs the same protocol — refs/protocol.md. The flags only change what Step 0 resolves. First match wins; flags compose.

InvocationAlso triggers on (natural language)Effect
/emulate"run the app", "open the simulator", "see it running", "show me the app"Platform resolved from devkit/PLATFORMS.md
/emulate --ios"boot the iOS sim", "run it on iPhone"iOS lane, PLATFORMS.md not consulted
/emulate --adr (alias --android)"run it on Android", "open the emulator"Android lane, PLATFORMS.md not consulted
/emulate --expo"start Expo", "run Metro", "expo go"Pins the runner; the platform still resolves normally
/emulate --device <name>"run it on an iPhone 15 Pro"Pins the simulator / AVD and skips the device question
/emulate --dry-run"what would this do", "don't actually run it"Prints the plan and the kill list, launches nothing, kills nothing
/emulate --help—This table, then stop

Two axes, not one. --ios and --adr pin the platform — a product fact, declared in devkit/PLATFORMS.md. --expo pins the runner — a repo fact, detected from the working tree, because Expo is a toolchain that targets both platforms rather than a platform of its own. --device is a third, orthogonal axis. /emulate --expo --ios --device "iPhone 15 Pro" is legal and means exactly what it reads like.

An unrecognised flag is never ignored. It stops the run with the flag named and the valid set printed — it never falls through to auto-detection.

The two contracts

Fail loudly. Where a wrong guess would cost the user a long build or boot the wrong thing, /emulate stops with a named cause, a non-zero exit and a copy-pasteable fix. It never invents a launch command, never fuzzy-matches a device name, and never boots something and hopes. The exit-code table lives in refs/protocol.md § Loud failures.

Ask only where the answer is genuinely the user's. Exactly two questions exist — which platform, when the repo declares more than one, and which device, when more than one is available. Both are asked in a single AskUserQuestion call, both offer a working default first, and nothing is killed or built until the answers land. A dismissed prompt falls back to the default and still launches.

Safety floor

/emulate writes nothing to the repo: no commits, no branches, no PRs, no PRD stamps, no report files. It is read-only against the working tree.

Its only side effect is in the OS process table, and it is bounded — see ../shared/refs/safety-floor.md and the allowlist compiled into script-emulate-sweep.sh.

Closing message

Every run ends with the closing message per ../shared/refs/closing-message.md, after the launch banner. A launched app is 🟢; a launch that started but reported a degraded state (dirty tree noted, a process that refused to die) is 🟡; a loud failure is 🔴 with the fix as step 1.

Harness incidents

Unexpected script failures, tool errors and retries are logged to devkit/DOCTOR.md per ../shared/refs/doctor-logging.md. A loud failure is not an incident — an absent toolchain or an undeclared platform is the contract working, not the harness misbehaving. Log only what was genuinely unexpected.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.