pub async fn run_lint(
input: LintInput,
repo_path: Option<&Path>,
context_dir: Option<&Path>,
strict: bool,
suggest: bool,
) -> Result<LintOutcome>Expand description
Non-interactive core for omni-dev git commit message lint.
Shared by the CLI and the MCP git_lint_commits tool. No AI client
involved — deterministic and synchronous under the hood, async only
for call-site parity with super::run_check.
repo_path selects the repository (None defaults to the current
working directory); context_dir overrides the .omni-dev/ resolution
chain for both scopes.yaml and commit-rules.yaml. suggest populates
a deterministic scope-fix suggestion per commit (see
crate::git::suggest_scope_fix) — report-only, mirroring the CLI’s
--suggest; it is an error to combine with LintInput::Message, which
has no changed-files list to resolve a scope from. There is no fix
equivalent here: applying amendments stays exclusive to the CLI’s
--fix and the git_amend_commits MCP tool.