pub struct Config {
pub out_dir: PathBuf,
pub preset: Preset,
pub strict: bool,
pub check: bool,
pub exclude: Vec<String>,
pub platforms: Vec<Platform>,
pub emit_error_catalog: bool,
}Expand description
Runtime configuration for a single aidoc invocation.
Fields§
§out_dir: PathBufOutput directory for generated artifacts. Defaults to
<repo>/docs/aidoc/ relative to the workspace root.
preset: PresetWhich artifact set to emit. Currently only Preset::Publish.
strict: boolIf true, promote lint warnings to errors and cause the pipeline to
exit with a non-zero code. Wired to --strict on the CLI.
check: boolIf true, run in check mode: generate artifacts into a temporary
directory and diff against the committed out_dir. Wired to
--check on the CLI. No files are written to out_dir.
exclude: Vec<String>Crate names to skip when enumerating the workspace. Sourced from
[workspace.metadata.aidoc].exclude.
platforms: Vec<Platform>External LLM-doc platforms to emit overlay artifacts for.
Each entry adds platform-specific files on top of the core
docs/aidoc/ output (e.g. context7.json at the repo root for
Platform::Context7). See the platform module for what each
overlay emits.
emit_error_catalog: boolIf true, additionally emit an error catalog: one
errors/<CODE>.md per catalogued diagnostic, a deterministic
errors/index.json, and a top-level llms-errors.txt. The
catalog is populated from every rustdoc item that derives
miette::Diagnostic — consumers add no dependency on
cargo-aidoc, only on miette. See crate::error_catalog for
the consumer contract.