{
  "definitions": [
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": false,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 16,
      "name": "STAGES",
      "signature": "const STAGES: readonly ((scope: StageScope) => Stage)[] = ["
    },
    {
      "callable": true,
      "callees": [],
      "callers": [],
      "exported": false,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 27,
      "name": "isDir",
      "signature": "const isDir = function isDir(value: string | null): value is string {"
    },
    {
      "callable": true,
      "callees": [],
      "callers": [],
      "exported": false,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 31,
      "name": "scopeOf",
      "signature": "const scopeOf = function scopeOf("
    },
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": false,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 36,
      "name": "scopedDirs",
      "signature": "const scopedDirs = scoped.map((member) => member.dir);"
    },
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": false,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 37,
      "name": "hasApp",
      "signature": "const hasApp = scoped.some((member) => member.id === APP_ID);"
    },
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": false,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 38,
      "name": "tsconfigs",
      "signature": "const tsconfigs = scopedDirs.map((dir) => `${dir}/${TSCONFIG}`).join(\",\");"
    },
    {
      "callable": true,
      "callees": [],
      "callers": [],
      "exported": true,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 50,
      "name": "stagesFor",
      "signature": "export const stagesFor = function stagesFor(options: StageOptions): StagePlan {"
    },
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": true,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 51,
      "name": "full",
      "signature": "const full = options.scope.size === 0;"
    },
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": true,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 52,
      "name": "scoped",
      "signature": "const scoped = MEMBERS.filter((member) => (full ? member.gated : options.scope.has(member.id)));"
    },
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": true,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 53,
      "name": "skippedWide",
      "signature": "const skippedWide: string[] = [];"
    },
    {
      "callable": true,
      "callees": [],
      "callers": [],
      "exported": true,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 54,
      "name": "wide",
      "signature": "const wide = function wide(steps: Step[]): Step[] {"
    },
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": true,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 61,
      "name": "scope",
      "signature": "const scope = scopeOf(scoped, options, wide);"
    },
    {
      "callable": false,
      "callees": [],
      "callers": [],
      "exported": true,
      "flow": "isolated",
      "kind": "lexical_declaration",
      "line": 62,
      "name": "stages",
      "signature": "const stages = STAGES.map((build) => build(scope)).filter((stage) => stage.steps.length > 0);"
    }
  ],
  "document": null,
  "findings": [],
  "generated": false,
  "href": "https://banes-lab.com/anatomy/pipeline#file-pipeline-core-factories-plan-factory-ts",
  "language": "typescript",
  "layer": "infrastructure",
  "name": "plan.factory.ts",
  "path": "core/factories/plan.factory.ts",
  "ref": "anatomy:file-pipeline-core-factories-plan-factory-ts",
  "relations": [
    {
      "links": [
        {
          "href": "https://banes-lab.com/anatomy/pipeline#folder-pipeline-core-factories",
          "json": "https://banes-lab.com/json/anatomy/pipeline/folder-pipeline-core-factories",
          "label": "core/factories",
          "markdown": "https://banes-lab.com/anatomy/pipeline/folder-pipeline-core-factories.md",
          "ref": "chapter:/anatomy/pipeline#folder-pipeline-core-factories"
        }
      ],
      "relation": "contained-in"
    },
    {
      "links": [
        {
          "href": "https://banes-lab.com/ontology#architecture-orchestration",
          "json": "https://banes-lab.com/json/records/architecture/orchestration",
          "label": "Orchestration",
          "markdown": "https://banes-lab.com/records/architecture/orchestration.md",
          "ref": "architecture:orchestration"
        },
        {
          "href": "https://banes-lab.com/ontology#architecture-fitness-functions",
          "json": "https://banes-lab.com/json/records/architecture/fitness-functions",
          "label": "Fitness Functions",
          "markdown": "https://banes-lab.com/records/architecture/fitness-functions.md",
          "ref": "architecture:fitness-functions"
        },
        {
          "href": "https://banes-lab.com/ontology#architecture-pipeline-architecture",
          "json": "https://banes-lab.com/json/records/architecture/pipeline-architecture",
          "label": "Pipeline Architecture",
          "markdown": "https://banes-lab.com/records/architecture/pipeline-architecture.md",
          "ref": "architecture:pipeline-architecture"
        },
        {
          "href": "https://banes-lab.com/ontology#architecture-policy-enforcement",
          "json": "https://banes-lab.com/json/records/architecture/policy-enforcement",
          "label": "Policy Enforcement",
          "markdown": "https://banes-lab.com/records/architecture/policy-enforcement.md",
          "ref": "architecture:policy-enforcement"
        },
        {
          "href": "https://banes-lab.com/ontology#architecture-policy-as-code",
          "json": "https://banes-lab.com/json/records/architecture/policy-as-code",
          "label": "Policy as Code",
          "markdown": "https://banes-lab.com/records/architecture/policy-as-code.md",
          "ref": "architecture:policy-as-code"
        }
      ],
      "relation": "evidence-for"
    }
  ],
  "slots": {
    "concern": "factory",
    "subject": "plan",
    "variant": null
  },
  "stats": {
    "bytes": 2156,
    "callable": 4,
    "definitions": 13,
    "edges": 0,
    "exported": 7,
    "files": 1,
    "findings": {},
    "flows": {
      "isolated": 13
    },
    "lines": {
      "blank": 4,
      "code": 60,
      "total": 64
    }
  },
  "summary": "60 lines of code and 13 definitions.",
  "text": "https://banes-lab.com/source/pipeline/core/factories/plan.factory.ts.txt",
  "tree": "pipeline",
  "siblings": {
    "next": {
      "href": "https://banes-lab.com/anatomy/pipeline#file-pipeline-core-factories-stage-factory-ts",
      "json": "https://banes-lab.com/json/source/pipeline/core/factories/stage.factory.ts",
      "label": "core/factories/stage.factory.ts",
      "markdown": "https://banes-lab.com/source/pipeline/core/factories/stage.factory.ts.md",
      "ref": "anatomy:file-pipeline-core-factories-stage-factory-ts"
    },
    "previous": {
      "href": "https://banes-lab.com/anatomy/pipeline#file-pipeline-core-factories-build-factory-ts",
      "json": "https://banes-lab.com/json/source/pipeline/core/factories/build.factory.ts",
      "label": "core/factories/build.factory.ts",
      "markdown": "https://banes-lab.com/source/pipeline/core/factories/build.factory.ts.md",
      "ref": "anatomy:file-pipeline-core-factories-build-factory-ts"
    }
  },
  "up": {
    "href": null,
    "json": "https://banes-lab.com/json/api/source/pipeline/core/factories",
    "label": "core/factories",
    "markdown": "https://banes-lab.com/api/source/pipeline/core/factories.md",
    "ref": "api:source/pipeline/core/factories"
  }
}
