Config File

Global configuration lives at ~/.config/meriadoc/config.yaml. It controls where Meriadoc looks for projects, how it caches validations, and where audit logs are written.

Override the config path with the MERIADOC_CONFIG environment variable (point it at the file, not the directory).

Full example

discovery:
  roots:
    - path: ~/projects
      enabled: true
    - path: ~/work/client
      enabled: true
    - path: ~/experiments
      enabled: false      # temporarily disabled
  max_depth: 3
  validate_on_discovery: true
  spec_files:
    - meriadoc.yaml
    - meriadoc.yml
    - merry.yaml
    - merry.yml

cache:
  enabled: true
  dir: ~/.config/meriadoc/cache

audit:
  enabled: false
  sinks:
    - type: file
      path: ~/.config/meriadoc/audit.log
    # - type: stderr

Discovery

Meriadoc walks each root directory up to max_depth levels deep, looking for any of the spec_files names.

FieldDefaultDescription
roots[]List of directories to search
max_depth3How deep to recurse into each root
validate_on_discoverytrueValidate specs when found (cached)
spec_filessee aboveFile names to treat as Meriadoc specs

Managing roots via CLI

meriadoc config add ~/my-project     # add a root
meriadoc config rm ~/my-project      # remove a root
meriadoc config ls                   # list all roots

Cache

Meriadoc caches spec validation results to avoid re-parsing unchanged files on every command.

cache:
  enabled: true
  dir: ~/.config/meriadoc/cache

Cache files are stored per-project under the configured dir. Disable caching if you’re editing specs frequently and want immediate feedback.

Audit

See Audit Logging for the full reference. Quick config:

audit:
  enabled: true
  sinks:
    - type: file
      path: ~/.config/meriadoc/audit.log   # NDJSON, append-only
    - type: stderr                          # good for containers / CI

Directory layout

~/.config/meriadoc/
├── config.yaml           # this file
├── cache/                # validation caches, per project
│   └── myproject-a1b2/
│       └── validation_cache.json
├── env/                  # saved env values, per project/task
│   └── myproject/
│       └── deploy.env
└── audit.log             # NDJSON audit log (when enabled)