repolish apply¶
Apply templates to the project. This is the main day-to-day command.
Options¶
| Option | Default | Description |
|---|---|---|
--config PATH, -c PATH |
repolish.yaml |
Path to the repolish YAML configuration file. |
--check |
off | Dry-run mode - load config and create context but do not write any files. |
--strict |
off | Exit 1 if any provider could not be registered. Recommended for CI. |
--standalone |
off | Bypass monorepo detection entirely and run a normal single-pass apply. Useful when running from inside a member package directory that is also a standalone project. |
--root-only |
off | Run only the root pass; skip member passes. Mutually exclusive with --member. |
--member NAME |
- | Run only the named member's full pass (repo-relative path or package name). The root pass is skipped. Mutually exclusive with --root-only. |
--skip-post-process |
off | Skip all post_process commands defined in repolish.yaml. |
What it does¶
repolish apply runs the full pipeline:
- Registration pass - every provider listed in
repolish.yamlis registered (or re-registered if its cached paths are stale). - Context pass - each provider's
create_context()is called, thenprovide_inputs()andfinalize_context()run to exchange cross-provider data. - Render pass - templates are rendered against the merged context and
written to disk, respecting file modes (
create-only,keep,delete). - Post-process pass - any
post_processshell commands fromrepolish.yamlare executed in order.
Check mode¶
--check stops after the context pass. No files are written. Use it to validate
that all providers load and produce a context without running a full apply:
CI usage¶
Pass --strict so that a provider registration failure becomes a hard error
rather than a warning:
Monorepo flags¶
In a monorepo repolish detects whether the current directory is the root or a member and runs the appropriate passes automatically. The explicit flags let you override this detection: