critiq check
Scan a repository, directory, or single file with the active Critiq catalog.
#Syntax
critiq check [target] [--base <git-ref>] [--head <git-ref>] [--format pretty|json]#Arguments
target: Repository, directory, or file to scan. Defaults to..
#Flags
--base <git-ref>: Base ref for a diff-scoped run.--head <git-ref>: Head ref for a diff-scoped run.--format pretty|json: Output format. Defaults topretty.
#Examples
npx critiq check .
npx critiq check src/api --format json
npx critiq check . --base origin/main --head HEAD#Defaults
targetdefaults to...critiq/config.yamlis loaded when present.- Diff mode requires both
--baseand--head. - Legacy
critiq check "<rules-glob>" .usage is rejected.
#JSON output
{
"command": "check",
"format": "json",
"exitCode": 1,
"findings": [],
"diagnostics": []
}#Exit behavior
0: scan completed without findings or user errors.1: findings, user/input errors, or validation diagnostics.2: internal/runtime errors.
#Notes
- TypeScript and JavaScript have the deepest support today.
- Go, Java, PHP, Python, Ruby, and Rust have narrower phase-one adapter coverage.