# plugin-scaffold-demo

Plugin scaffold generated by `zenzic init --plugin plugin-scaffold-demo`.
This is the reference example for writing custom Zenzic rule plugins.

## What it demonstrates

| Feature | Where |
| --- | --- |
| Public SDK import | `from zenzic.rules import BaseRule, RuleFinding` |
| `run_rule()` test helper | `tests/test_rules.py` |
| Entry-point registration | `pyproject.toml` `[project.entry-points]` |
| Hatchling packaging | `pyproject.toml` `[build-system]` |

## Quick start

```bash
uv sync
uv pip install -e .
zenzic plugins list
```

## Testing your rule

```bash
pytest tests/test_rules.py -v
```

The test uses `run_rule()` — a one-call helper that creates a virtual Markdown
file, runs the rule engine, and returns findings. No engine setup required.

## Enable in a target project

Add to `zenzic.toml`:

```toml
plugins = ["plugin-scaffold-demo"]
```
