Skip to main content

Shared run flags

run, dev, task, and x share a common set of grant and engine flags:
FlagDescription
--allow-clockUse the real system clock (run is no longer reproducible).
--allow-randomUse OS entropy for Math.random / crypto.getRandomValues.
--allow-env[=NAMES]Expose host env. Bare = all; =A,B scopes to those names.
--trustGrant full host access (clock + random + env).
--max-old-space-size <MiB>V8 heap limit, like Node. Also read from NODE_OPTIONS.
--v8-flags <FLAGS>Pass comma-separated flags straight to V8.
See Permissions for the grant model.

meow init

Scaffold a new project in the current directory.
meow init
meow init --mode node-compat
meow init --force --no-install
FlagDefaultDescription
--mode <mode>strict-webstrict-web or node-compat.
--forceoffOverwrite existing meow.config.json / package.json.
--no-installoffSkip the dependency install after scaffolding.
Writes meow.config.json, a minimal package.json, and a starter main.ts; runs meow sync; then meow install (unless --no-install).

meow run

Execute a file or a package.json script.
meow run main.ts
meow run build
meow run app.ts -- --port 8080      # forward args after --
meow run app.ts --allow-clock
ArgumentDescription
<target>A script name (matched in package.json first) or a file path.
-- <args…>Arguments forwarded to your program as argv.
Plus the shared run flags.

meow dev

Shorthand for meow run dev, with a cold-start banner.
meow dev
meow dev -- --host 0.0.0.0
Accepts the shared run flags and -- <args…>.

meow task

Run a package.json script by name (explicit form, no file-path inference).
meow task build
meow task deploy -- --dry-run
ArgumentDescription
<name>The script name in package.json.
-- <args…>Forwarded arguments.

meow test

Discover and run the test suite in deterministic V8 isolates.
meow test
meow runs every *.test.* / *.spec.* file (.ts, .tsx, .js, .jsx, .mts, .mjs, .cts, .cjs), each in its own hermetic isolate, and prints a pass/fail summary. Exits non-zero if any test fails. Tests use the meow:test API. See Testing.

meow x

Ephemeral package execution — install to a temp workspace, run, discard. Aliased as execute, and reachable via the npx/bunx/meowx binary names.
meow x create-vite my-app
meow x prettier@latest . --write
meow x wrangler deploy --trust       # grants may trail the package
ArgumentDescription
<package>Package to run, optionally @version or @tag.
<args…>Forwarded to the package’s binary (no -- needed).
Accepts the shared run flags; they may also appear after the package name. MEOW_DANGEROUSLY_DISABLE_SECURITY=1 grants trust persistently.

eval & print

Run inline source without a file.
meow -e "console.log(2 + 2)"
meow -p "Math.max(3, 7)"           # wraps the expression in console.log
FlagDescription
-e, --evalEvaluate the given source.
-p, --printEvaluate and print the result.

Package commands

install, add, remove, search.