stricter checks
CI / verify (pull_request) Successful in 12s

This commit is contained in:
2026-10-10 15:16:53 +02:00
parent ced43fbb11
commit 513d51f702
30 changed files with 984 additions and 470 deletions
+62
View File
@@ -0,0 +1,62 @@
/** @type {import('dependency-cruiser').IConfiguration} */
module.exports = {
forbidden: [
{
name: "no-circular",
severity: "error",
from: {},
to: { circular: true },
},
{
name: "no-orphans",
severity: "error",
from: { orphan: true, pathNot: ["\\.d\\.ts$"] },
to: {},
},
{
name: "not-to-unresolvable",
severity: "error",
from: {},
to: { couldNotResolve: true, pathNot: ["^bun:"] },
},
{
name: "quota-is-standalone",
comment: "Quota ships independently of Agents and Multi-work.",
severity: "error",
from: { path: "^src/quota/" },
to: { path: "^src/(agents|multi-work)/" },
},
{
name: "agents-is-standalone",
comment: "Agents must load without Quota or Multi-work.",
severity: "error",
from: { path: "^src/agents/" },
to: { path: "^src/(quota|multi-work)/" },
},
{
name: "multi-work-not-to-quota",
comment: "Multi-work may build on Agents but not on Quota.",
severity: "error",
from: { path: "^src/multi-work/" },
to: { path: "^src/quota/" },
},
{
name: "src-not-to-scripts-or-tests",
severity: "error",
from: { path: "^src/" },
to: { path: "^(scripts|tests)/" },
},
],
options: {
doNotFollow: { path: "node_modules" },
tsConfig: { fileName: "tsconfig.json" },
tsPreCompilationDeps: true,
// TypeScript 7 has no compiler API yet; swc parses TS/TSX for the cruise.
parser: "swc",
enhancedResolveOptions: {
exportsFields: ["exports"],
conditionNames: ["import", "types", "bun", "default"],
extensions: [".ts", ".tsx", ".js", ".d.ts"],
},
},
};