CLI commands

master-css generate

Generate CSS from project source files.

Invocation and options

Invocation
master-css generate [options] [source paths...]

Run from the project root. Omit source paths for ordinary source discovery, or quote a path/glob argument to scope the scan. Explicit paths replace the default file selection; they are not additional includes. The generated output combines discovered stylesheet entries and scanned classes.

source paths
path[]Optional

The glob pattern paths to scan sources

-w, --watch
flagOptional

Watch file changes and generate CSS rules.

-o, --output <path>
valueOptional

Specify your CSS file output path (default: "master.css")

-v, --verbose <level>
valueOptional

Verbose logging 0~N (default: "1")

--binding <binding>
valueOptional

Execution binding: auto, native, or wasm. (choices: "auto", "native", "wasm", default: "auto")

--no-export
flagOptional

Print only CSS results.

--strict
flagOptional

Fail CSS syntax or value validation before publishing any generated assets.

--prune-native-css
flagOptional

Prune unused native CSS only in project-owned source files.

-h, --help
flagOptional

display help for command

Complete command help
TEXT
Usage: master-css generate [options] [source paths...]Generate CSS from project source files.Arguments:  source paths           The glob pattern paths to scan sourcesOptions:  -w, --watch            Watch file changes and generate CSS rules.  -o, --output <path>    Specify your CSS file output path (default:                         "master.css")  -v, --verbose <level>  Verbose logging 0~N (default: "1")  --binding <binding>    Execution binding: auto, native, or wasm. (choices:                         "auto", "native", "wasm", default: "auto")  --no-export            Print only CSS results.  --strict               Fail CSS syntax or value validation before publishing                         any generated assets.  --prune-native-css     Prune unused native CSS only in project-owned source                         files.  -h, --help             display help for command

Effects and lifecycle

By default, the command publishes master.css or the path selected by --output. A stylesheet graph can also publish associated stylesheets and resources beside that output. --no-export prints CSS without publishing those files.

--watch keeps scanning for changes until interrupted. A failed rebuild is reported on stderr while the watcher remains active; a running watcher alone does not establish that its latest rebuild succeeded.

Output and errors

With --no-export, CSS goes to stdout. Scanner progress also uses stdout at the default verbosity; add --verbose 0 when piping or saving CSS. Export notices and watch status go to stderr. Generate has no JSON diagnostic format or diagnostic exit-code switches; use lint or inspect for those reports. Review errors and the generated stylesheet before loading it into the application.

Example

Run from the project root after installing the CLI:

Inspect generated CSS without writing output files:

SH
master-css generate \  --no-export \  --verbose 0

Publish CSS to an explicit file:

SH
master-css generate \  --output master.css

Regenerate that output when project sources change; stop with Ctrl+C:

SH
master-css generate \  --watch \  --output master.css

See the CLI guide for setup.


© 2026 Aoyue Design LLC.MIT License
Trademark Policy