Skip to content

Quick Start

  1. Generate mille.toml with mille init

    Terminal window
    mille init

    mille analyzes actual import statements in your source files to infer layer structure and dependencies:

    Detected languages: rust
    Scanning imports...
    Using layer depth: 2
    Inferred layer structure:
    domain ← (no internal dependencies)
    usecase → domain
    external: anyhow
    infrastructure → domain
    external: serde, tokio
    Generated 'mille.toml'

    Review the generated config and adjust as needed.

  2. Visualize with mille analyze (optional)

    Terminal window
    mille analyze

    Inspect the actual dependency graph before enforcing rules. Generate an SVG for browser viewing:

    Terminal window
    mille analyze --format svg > graph.svg && open graph.svg
  3. Run mille check

    Terminal window
    mille check

    Exits with code 0 if no violations are found.

  4. Add to CI

    For GitHub Actions:

    - run: mille check --format github-actions

    Violations appear as annotations directly in PR reviews.

Next Steps