lintkit

module
v0.0.0-...-251f90f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 9, 2026 License: MIT

README

lintkit

Static analysis utilities that output SARIF.

Overview

A collection of lightweight linters and checks for artifacts that don't fit traditional AST-based analysis. All tools emit SARIF for interoperability with editors, CI systems, and visualization tools.

Tools

  • docsprawl: Analyze markdown sprawl and emit SARIF for documentation hygiene issues.

  • dbsanity: Compare SQLite table row counts against a JSON baseline and emit SARIF when drift exceeds a threshold.

lintkit dbsanity --baseline counts.json --threshold 20 path/to/db.sqlite

Baseline format:

{
  "tables": {
    "nugs": 1000,
    "tags": 2000
  }
}

Tables present in the database but missing from the baseline are ignored. Tables missing from the database are treated as a 100% drop.

  • wikifmt: Recursively scans wiki-style Markdown files for frontmatter validity, broken wikilinks/Markdown links, and basic tag hygiene. Results are emitted as SARIF for easy consumption by editors or CI systems.
lintkit wikifmt ROOT...
  • stale: Detect derived artifacts that are older than their sources based on a YAML configuration file. Emits SARIF with ruleId of stale-artifact and a driver name of lintkit-stale.

Example rules file:

rules:
  - derived: "go.sum"
    source: "go.mod"
  - derived: "*_gen.go"
    source: "*.proto"
  - derived: ".orca/views/*.jsonl"
    source: ".orca/knowledge.db"

Run against one or more paths (defaults to the current directory):

lintkit stale --rules staleness.yml ./...
  • nuglint: Validate knowledge nuggets stored in .orca/kg/*.jsonl files. Outputs SARIF findings to stdout.
lintkit nuglint path/to/repo
  • filesize: Reports file metrics and enforces simple size budgets. Outputs SARIF only.
lintkit filesize --rules .filesize.yml [PATH...]

Example rules file:

rules:
  - pattern: "*.go"
    max: 500        # lines
  - pattern: "*.json"
    max: 100KB      # bytes
  - pattern: "go.sum"
    max: 50KB       # bytes

Patterns use Go's filepath.Match semantics. When a file exceeds its configured limit, the linter emits a filesize-budget result identifying the file, actual size, and allowed maximum.

  • nobackups: Detects backup or temporary files that should not be committed to a repository. Findings are emitted in SARIF format with the ruleId set to nobackups.
lintkit nobackups [PATH...]
  • jsonl: Validate JSONL files against a JSON Schema. Emits SARIF findings.
lintkit jsonl --schema schema.json file.jsonl [file2.jsonl...]
  • dbschema: Compare a SQLite database's schema against an expected DDL file and emit SARIF findings for missing/extra tables or columns.
lintkit dbschema --expected schema.sql path/to/app.sqlite

License

MIT

Directories

Path Synopsis
cmd
archcheck command
Command archcheck validates architecture boundaries in Go projects.
Command archcheck validates architecture boundaries in Go projects.
embedhealth command
Command embedhealth checks embedding health in the knowledge graph.
Command embedhealth checks embedding health in the knowledge graph.
filesize command
Command filesize analyzes Go file sizes and outputs SARIF, check, or human-readable format.
Command filesize analyzes Go file sizes and outputs SARIF, check, or human-readable format.
html-hygiene command
Command html-hygiene validates exported HTML for broken links and structural integrity.
Command html-hygiene validates exported HTML for broken links and structural integrity.
jtbd command
Command jtbd reports test coverage mapped to user goals (Jobs To Be Done).
Command jtbd reports test coverage mapped to user goals (Jobs To Be Done).
lintkit command
Command lintkit provides a unified CLI for running various code quality linters.
Command lintkit provides a unified CLI for running various code quality linters.
mcp-logscan command
Command mcp-logscan scans MCP server logs for errors and warnings.
Command mcp-logscan scans MCP server logs for errors and warnings.
mdsanity command
Command mdsanity validates markdown link integrity and reports broken links.
Command mdsanity validates markdown link integrity and reports broken links.
nugstats command
Command nugstats reports knowledge graph nugget statistics.
Command nugstats reports knowledge graph nugget statistics.
signals command
Command signals analyzes tool call telemetry to identify improvement opportunities.
Command signals analyzes tool call telemetry to identify improvement opportunities.
pkg
check
Package check provides types and helpers for the lintkit-check output format.
Package check provides types and helpers for the lintkit-check output format.
dbsanity
Package dbsanity checks SQLite row counts against baselines and configs.
Package dbsanity checks SQLite row counts against baselines and configs.
dbschema
Package dbschema compares SQLite schemas against expected DDL files.
Package dbschema compares SQLite schemas against expected DDL files.
docsprawl
Package docsprawl analyzes markdown sprawl and emits SARIF reports.
Package docsprawl analyzes markdown sprawl and emits SARIF reports.
filesize
Package filesize checks file sizes against budget rules.
Package filesize checks file sizes against budget rules.
jsonl
Package jsonl validates JSONL files against JSON Schema.
Package jsonl validates JSONL files against JSON Schema.
mdsanity
Package mdsanity provides markdown link validation and sanity checks.
Package mdsanity provides markdown link validation and sanity checks.
nobackups
Package nobackups detects backup and temporary files in the codebase.
Package nobackups detects backup and temporary files in the codebase.
nuglint
Package nuglint provides linting for ORCA knowledge nugget JSONL files.
Package nuglint provides linting for ORCA knowledge nugget JSONL files.
sarif
Package sarif provides types and helpers for emitting SARIF output.
Package sarif provides types and helpers for emitting SARIF output.
stale
Package stale detects stale artifacts based on mtime rules.
Package stale detects stale artifacts based on mtime rules.
wikifmt
Package wikifmt checks wiki-style markdown files for formatting issues.
Package wikifmt checks wiki-style markdown files for formatting issues.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL