Anchored Standard Enterprise Lint & Schema Guardian

Anchored Standard Enterprise Lint & Schema Guardian

@xiaobright/dsh-anchored-standard·v1.2.0·core

An enterprise static analysis and regulatory compliance guardrail for DeepSeek Harness. Automates ESLint, Prettier, and SonarQube rule enforcement to ensure pristine agent-generated code.

Quality-Gate · Linter · Static-Analysis · Compliance

GitHubNPM
Installation & Integration
bash
manager:
$ pnpm add @xiaobright/dsh-anchored-standard

Architecture

Anchored Standard guarantees that every line of code synthesized by DeepSeek Harness meets strict corporate standards. Autonomous models occasionally introduce unapproved dependencies, violate team formatting rules, or write high-complexity methods. This plugin integrates static analysis quality gates directly into the Cordis commit pipeline. Acting as an uncompromising automated linter, it validates cyclomatic complexity, enforces ESLint and Prettier conventions, and audits open-source licenses to prevent GPL contamination—guaranteeing enterprise-grade code hygiene.

Core Features

01

Strict Quality Gate: Zero-tolerance barrier blocking non-compliant code from committing

02

Open Source License Guard: Shields commercial proprietary software against copyleft contagion

03

Silent Formatting Auto-Fix: Prettier integration fixes formatting without burning extra model tokens

04

Cyclomatic Complexity Ceiling: Prevents agents from generating unmaintainable nested spaghetti logic

Core Workflow

01

Staged Diff Interception

Intercepts staged code diffs before filesystem persistence occurs.

02

Multi-Engine Static Scan

Runs concurrent TypeScript checks, ESLint rules, and complexity scorers.

03

License & Dependency Audit

Scans newly introduced packages against license and CVE vulnerability databases.

04

Auto-Fix & Gate Feedback

Auto-fixes minor styling flaws; halts critical violations with diagnostic guidance.

Configuration Parameters Reference (YAML / JSON)

ParameterTypeDefaultDescription
maxCyclomaticComplexitynumber12Maximum cyclomatic complexity per function
prohibitedLicensesstringGPL-3.0,AGPL-3.0Prohibited copyleft licenses comma-separated
autoFixFormattingbooleantrueAutomatically apply Prettier formatting fixes