Skip to content

Architecture

Design decisions are recorded as architecture decision records in adrs/. Read them before proposing a change in direction.

Crate Role
skif-cli The command line: argument parsing, exit codes, install step after fixes.
skif Embeddable facade: discover a workspace, lint it and plan fixes without IO side effects.
skif-config skif.toml model, loading, CLI overrides and the JSON Schema.
skif-core Diagnostic, fix, report and filesystem types shared by the other crates.
skif-workspace Workspace discovery for npm, pnpm, yarn and bun: packages, manifests and catalogs.
skif-lint Rule engine: rule registry, diagnostic emitter and parallel runner.
skif-rules Built-in manifest, workspace, policy and catalog rules.
skif-specifier npm dependency specifier parsing and comparison, vendored from syncpack.
skif-edit Format-preserving JSON and YAML edits used by autofixes.
skif-report Human, JSON, TOON, SARIF, GitHub, Code Climate, compact, Markdown and CODEOWNERS renderers.
skif-js JavaScript and TypeScript module graph and dependency rules, built on oxc.
skif-js-syntax oxc-based module facts and static config extraction; never executes code.
skif-js-plugins package.json script parsing and the declarative plugin table.
skif-migrate The translation behind skif migrate: sherif, syncpack and knip configuration to skif.toml.
skif-node The Node-API addon behind the npm package.

The full list is the ADR index.

  1. skif-config resolves defaults, then the skif.toml files from the root up to the ceiling (merged farthest first), then CLI overrides.
  2. skif-workspace discovers packages and reports facts; it never decides that a fact is a problem. A run over several roots discovers each root and gives it its own configuration.
  3. skif-lint builds a registry from the rule providers, validates every rule’s options, and runs the providers concurrently. Rules emit diagnostics, optionally with fixes.
  4. The JS analysis (skif-js, with skif-js-syntax and skif-js-plugins) is one of those providers. It parses the sources, builds the module graph, applies the plugin table and emits the js rules.
  5. skif-edit turns fixes into a FixPlan of format-preserving edits; the CLI writes the plan.
  6. skif-report renders the report as human, JSON, TOON, SARIF, GitHub, Code Climate, compact, Markdown or CODEOWNERS output.