@maverickcer/env-cap 0.7.4 → 0.7.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ADOPTION.md +106 -124
- package/AGENTS.md +94 -128
- package/CHANGELOG.md +42 -0
- package/CODE_REVIEW.md +69 -173
- package/CONTRIBUTING.md +57 -74
- package/GUIDE.md +405 -866
- package/README.md +112 -89
- package/RELEASING.md +81 -65
- package/SECURITY.md +76 -227
- package/SUPPORT.md +21 -45
- package/VERSIONING.md +69 -105
- package/benchmarks/READING-BENCHMARKS.md +103 -81
- package/benchmarks/README.md +12 -9
- package/benchmarks/WRITING-BENCHMARKS.md +90 -80
- package/benchmarks/performance-buildtime/BENCHMARKS.md +20 -20
- package/benchmarks/performance-runtime/BENCHMARKS.md +107 -107
- package/dist/.dts/_ipc/build-fs.d.ts +12 -17
- package/dist/.dts/_ipc/build-fs.d.ts.map +1 -1
- package/dist/.dts/_ipc/compiler-api.d.ts +6 -6
- package/dist/.dts/_ipc/display-path.d.ts +1 -1
- package/dist/.dts/_ipc/display-path.d.ts.map +1 -1
- package/dist/.dts/_ipc/generated-banner.d.ts +8 -8
- package/dist/.dts/_ipc/glob.d.ts +9 -8
- package/dist/.dts/_ipc/glob.d.ts.map +1 -1
- package/dist/.dts/_ipc/no-node-fs.d.ts +2 -2
- package/dist/.dts/_ipc/no-node-fs.d.ts.map +1 -1
- package/dist/.dts/_ipc/resolve-tsconfig-paths.d.ts +16 -16
- package/dist/.dts/_ipc/resolve-tsconfig-paths.d.ts.map +1 -1
- package/dist/.dts/_ipc/typescript.d.ts +4 -4
- package/dist/.dts/build/assemble-project.d.ts +14 -15
- package/dist/.dts/build/assemble-project.d.ts.map +1 -1
- package/dist/.dts/build/change-model.d.ts +14 -14
- package/dist/.dts/build/change-model.d.ts.map +1 -1
- package/dist/.dts/build/check-artifacts.d.ts +4 -4
- package/dist/.dts/build/check-artifacts.d.ts.map +1 -1
- package/dist/.dts/build/citation-verification.d.ts +13 -14
- package/dist/.dts/build/citation-verification.d.ts.map +1 -1
- package/dist/.dts/build/compatibility.d.ts +24 -24
- package/dist/.dts/build/compatibility.d.ts.map +1 -1
- package/dist/.dts/build/contract-model.d.ts +10 -10
- package/dist/.dts/build/contract-model.d.ts.map +1 -1
- package/dist/.dts/build/deep-equal.d.ts +2 -2
- package/dist/.dts/build/deep-freeze.d.ts +2 -2
- package/dist/.dts/build/dependency-graph.d.ts +48 -55
- package/dist/.dts/build/dependency-graph.d.ts.map +1 -1
- package/dist/.dts/build/dependency-model.d.ts +18 -18
- package/dist/.dts/build/dependency-model.d.ts.map +1 -1
- package/dist/.dts/build/discover.d.ts +11 -11
- package/dist/.dts/build/discover.d.ts.map +1 -1
- package/dist/.dts/build/docs.d.ts +34 -38
- package/dist/.dts/build/docs.d.ts.map +1 -1
- package/dist/.dts/build/env-example.d.ts +13 -13
- package/dist/.dts/build/env-example.d.ts.map +1 -1
- package/dist/.dts/build/errors.d.ts +8 -8
- package/dist/.dts/build/evidence-cache.d.ts +23 -23
- package/dist/.dts/build/evidence-cache.d.ts.map +1 -1
- package/dist/.dts/build/evidence-model.d.ts +3 -3
- package/dist/.dts/build/evidence-reference.d.ts +15 -15
- package/dist/.dts/build/evidence-reference.d.ts.map +1 -1
- package/dist/.dts/build/evidence-snapshot.d.ts +47 -53
- package/dist/.dts/build/evidence-snapshot.d.ts.map +1 -1
- package/dist/.dts/build/exclusive-group.d.ts +4 -4
- package/dist/.dts/build/exclusive-group.d.ts.map +1 -1
- package/dist/.dts/build/finding-model.d.ts +12 -12
- package/dist/.dts/build/finding-model.d.ts.map +1 -1
- package/dist/.dts/build/generate-documentation.d.ts +19 -19
- package/dist/.dts/build/generate-documentation.d.ts.map +1 -1
- package/dist/.dts/build/generate-env-artifacts.d.ts +43 -43
- package/dist/.dts/build/generate-env-artifacts.d.ts.map +1 -1
- package/dist/.dts/build/generate-evidence.d.ts +19 -19
- package/dist/.dts/build/generate-evidence.d.ts.map +1 -1
- package/dist/.dts/build/generate-manifest.d.ts +11 -12
- package/dist/.dts/build/generate-manifest.d.ts.map +1 -1
- package/dist/.dts/build/generate-usage.d.ts +23 -24
- package/dist/.dts/build/generate-usage.d.ts.map +1 -1
- package/dist/.dts/build/generated-banner.d.ts +5 -5
- package/dist/.dts/build/governance-fields.d.ts +7 -7
- package/dist/.dts/build/humanize-key.d.ts +1 -1
- package/dist/.dts/build/humanize-key.d.ts.map +1 -1
- package/dist/.dts/build/index.d.ts +20 -36
- package/dist/.dts/build/index.d.ts.map +1 -1
- package/dist/.dts/build/lifecycle-model.d.ts +90 -83
- package/dist/.dts/build/lifecycle-model.d.ts.map +1 -1
- package/dist/.dts/build/link.d.ts +38 -39
- package/dist/.dts/build/link.d.ts.map +1 -1
- package/dist/.dts/build/literal-eval.d.ts +2 -2
- package/dist/.dts/build/literal-eval.d.ts.map +1 -1
- package/dist/.dts/build/live-expirations.d.ts +14 -13
- package/dist/.dts/build/live-expirations.d.ts.map +1 -1
- package/dist/.dts/build/manifest.d.ts +6 -6
- package/dist/.dts/build/map-utils.d.ts +4 -4
- package/dist/.dts/build/merge-documentation.d.ts +9 -8
- package/dist/.dts/build/merge-documentation.d.ts.map +1 -1
- package/dist/.dts/build/ownership-model.d.ts +14 -15
- package/dist/.dts/build/ownership-model.d.ts.map +1 -1
- package/dist/.dts/build/parse.d.ts +20 -21
- package/dist/.dts/build/parse.d.ts.map +1 -1
- package/dist/.dts/build/reference-projections.d.ts +36 -38
- package/dist/.dts/build/reference-projections.d.ts.map +1 -1
- package/dist/.dts/build/resolution/resolve-import.d.ts +18 -14
- package/dist/.dts/build/resolution/resolve-import.d.ts.map +1 -1
- package/dist/.dts/build/resolution/resolve-package-schema.d.ts +26 -26
- package/dist/.dts/build/resolution/resolve-package-schema.d.ts.map +1 -1
- package/dist/.dts/build/resolution/resolve-within-root.d.ts +9 -9
- package/dist/.dts/build/sarif.d.ts +5 -5
- package/dist/.dts/build/sarif.d.ts.map +1 -1
- package/dist/.dts/build/scan-dependencies.d.ts +17 -16
- package/dist/.dts/build/scan-dependencies.d.ts.map +1 -1
- package/dist/.dts/build/sort-by-identity.d.ts +1 -1
- package/dist/.dts/build/source-position.d.ts +13 -13
- package/dist/.dts/build/tool-version.d.ts +1 -1
- package/dist/.dts/build/usage-report.d.ts +19 -19
- package/dist/.dts/build/usage-report.d.ts.map +1 -1
- package/dist/.dts/eslint-plugin/index.d.ts +16 -5
- package/dist/.dts/eslint-plugin/index.d.ts.map +1 -1
- package/dist/.dts/eslint-plugin/no-raw-process-env.d.ts +4 -4
- package/dist/.dts/evidence/define-projection.d.ts +15 -16
- package/dist/.dts/evidence/define-projection.d.ts.map +1 -1
- package/dist/.dts/evidence/index.d.ts +11 -15
- package/dist/.dts/evidence/index.d.ts.map +1 -1
- package/dist/.dts/helpers/index.d.ts +15 -18
- package/dist/.dts/helpers/index.d.ts.map +1 -1
- package/dist/.dts/helpers/validators.d.ts +2 -2
- package/dist/.dts/helpers/validators.d.ts.map +1 -1
- package/dist/.dts/node/index.d.ts +19 -0
- package/dist/.dts/node/index.d.ts.map +1 -1
- package/dist/.dts/runtime/create.d.ts +6 -3
- package/dist/.dts/runtime/create.d.ts.map +1 -1
- package/dist/.dts/runtime/document.d.ts +91 -97
- package/dist/.dts/runtime/document.d.ts.map +1 -1
- package/dist/.dts/runtime/errors.d.ts +5 -5
- package/dist/.dts/runtime/index.d.ts +11 -10
- package/dist/.dts/runtime/index.d.ts.map +1 -1
- package/dist/.dts/runtime/reset.d.ts +1 -1
- package/dist/.dts/runtime/types.d.ts +39 -24
- package/dist/.dts/runtime/types.d.ts.map +1 -1
- package/dist/.dts/runtime/validate.d.ts +15 -2
- package/dist/.dts/runtime/validate.d.ts.map +1 -1
- package/dist/.dts7/_ipc/build-fs.d.ts +48 -0
- package/dist/.dts7/_ipc/build-fs.d.ts.map +1 -0
- package/dist/.dts7/_ipc/compiler-api.d.ts +17 -0
- package/dist/.dts7/_ipc/compiler-api.d.ts.map +1 -0
- package/dist/.dts7/_ipc/display-path.d.ts +27 -0
- package/dist/.dts7/_ipc/display-path.d.ts.map +1 -0
- package/dist/.dts7/_ipc/generated-banner.d.ts +58 -0
- package/dist/.dts7/_ipc/generated-banner.d.ts.map +1 -0
- package/dist/.dts7/_ipc/glob.d.ts +23 -0
- package/dist/.dts7/_ipc/glob.d.ts.map +1 -0
- package/dist/.dts7/_ipc/no-node-fs.d.ts +21 -0
- package/dist/.dts7/_ipc/no-node-fs.d.ts.map +1 -0
- package/dist/.dts7/_ipc/resolve-tsconfig-paths.d.ts +134 -0
- package/dist/.dts7/_ipc/resolve-tsconfig-paths.d.ts.map +1 -0
- package/dist/.dts7/_ipc/typescript.d.ts +20 -0
- package/dist/.dts7/_ipc/typescript.d.ts.map +1 -0
- package/dist/.dts7/build/assemble-project.d.ts +46 -0
- package/dist/.dts7/build/assemble-project.d.ts.map +1 -0
- package/dist/.dts7/build/change-model.d.ts +63 -0
- package/dist/.dts7/build/change-model.d.ts.map +1 -0
- package/dist/.dts7/build/check-artifacts.d.ts +48 -0
- package/dist/.dts7/build/check-artifacts.d.ts.map +1 -0
- package/dist/.dts7/build/citation-verification.d.ts +61 -0
- package/dist/.dts7/build/citation-verification.d.ts.map +1 -0
- package/dist/.dts7/build/compatibility.d.ts +83 -0
- package/dist/.dts7/build/compatibility.d.ts.map +1 -0
- package/dist/.dts7/build/compiler-api.d.ts +12 -0
- package/dist/.dts7/build/compiler-api.d.ts.map +1 -0
- package/dist/.dts7/build/contract-model.d.ts +93 -0
- package/dist/.dts7/build/contract-model.d.ts.map +1 -0
- package/dist/.dts7/build/deep-equal.d.ts +9 -0
- package/dist/.dts7/build/deep-equal.d.ts.map +1 -0
- package/dist/.dts7/build/deep-freeze.d.ts +20 -0
- package/dist/.dts7/build/deep-freeze.d.ts.map +1 -0
- package/dist/.dts7/build/dependency-graph.d.ts +163 -0
- package/dist/.dts7/build/dependency-graph.d.ts.map +1 -0
- package/dist/.dts7/build/dependency-model.d.ts +81 -0
- package/dist/.dts7/build/dependency-model.d.ts.map +1 -0
- package/dist/.dts7/build/discover.d.ts +41 -0
- package/dist/.dts7/build/discover.d.ts.map +1 -0
- package/dist/.dts7/build/display-path.d.ts +6 -0
- package/dist/.dts7/build/display-path.d.ts.map +1 -0
- package/dist/.dts7/build/docs.d.ts +172 -0
- package/dist/.dts7/build/docs.d.ts.map +1 -0
- package/dist/.dts7/build/env-example.d.ts +85 -0
- package/dist/.dts7/build/env-example.d.ts.map +1 -0
- package/dist/.dts7/build/errors.d.ts +78 -0
- package/dist/.dts7/build/errors.d.ts.map +1 -0
- package/dist/.dts7/build/evidence-cache.d.ts +74 -0
- package/dist/.dts7/build/evidence-cache.d.ts.map +1 -0
- package/dist/.dts7/build/evidence-model.d.ts +50 -0
- package/dist/.dts7/build/evidence-model.d.ts.map +1 -0
- package/dist/.dts7/build/evidence-reference.d.ts +67 -0
- package/dist/.dts7/build/evidence-reference.d.ts.map +1 -0
- package/dist/.dts7/build/evidence-snapshot.d.ts +142 -0
- package/dist/.dts7/build/evidence-snapshot.d.ts.map +1 -0
- package/dist/.dts7/build/exclusive-group.d.ts +19 -0
- package/dist/.dts7/build/exclusive-group.d.ts.map +1 -0
- package/dist/.dts7/build/finding-model.d.ts +80 -0
- package/dist/.dts7/build/finding-model.d.ts.map +1 -0
- package/dist/.dts7/build/generate-documentation.d.ts +176 -0
- package/dist/.dts7/build/generate-documentation.d.ts.map +1 -0
- package/dist/.dts7/build/generate-env-artifacts.d.ts +191 -0
- package/dist/.dts7/build/generate-env-artifacts.d.ts.map +1 -0
- package/dist/.dts7/build/generate-evidence.d.ts +77 -0
- package/dist/.dts7/build/generate-evidence.d.ts.map +1 -0
- package/dist/.dts7/build/generate-manifest.d.ts +100 -0
- package/dist/.dts7/build/generate-manifest.d.ts.map +1 -0
- package/dist/.dts7/build/generate-usage.d.ts +94 -0
- package/dist/.dts7/build/generate-usage.d.ts.map +1 -0
- package/dist/.dts7/build/generated-banner.d.ts +43 -0
- package/dist/.dts7/build/generated-banner.d.ts.map +1 -0
- package/dist/.dts7/build/glob.d.ts +6 -0
- package/dist/.dts7/build/glob.d.ts.map +1 -0
- package/dist/.dts7/build/governance-fields.d.ts +34 -0
- package/dist/.dts7/build/governance-fields.d.ts.map +1 -0
- package/dist/.dts7/build/humanize-key.d.ts +14 -0
- package/dist/.dts7/build/humanize-key.d.ts.map +1 -0
- package/dist/.dts7/build/index.d.ts +89 -0
- package/dist/.dts7/build/index.d.ts.map +1 -0
- package/dist/.dts7/build/lifecycle-model.d.ts +181 -0
- package/dist/.dts7/build/lifecycle-model.d.ts.map +1 -0
- package/dist/.dts7/build/link.d.ts +222 -0
- package/dist/.dts7/build/link.d.ts.map +1 -0
- package/dist/.dts7/build/literal-eval.d.ts +24 -0
- package/dist/.dts7/build/literal-eval.d.ts.map +1 -0
- package/dist/.dts7/build/live-expirations.d.ts +48 -0
- package/dist/.dts7/build/live-expirations.d.ts.map +1 -0
- package/dist/.dts7/build/manifest.d.ts +31 -0
- package/dist/.dts7/build/manifest.d.ts.map +1 -0
- package/dist/.dts7/build/map-utils.d.ts +8 -0
- package/dist/.dts7/build/map-utils.d.ts.map +1 -0
- package/dist/.dts7/build/merge-documentation.d.ts +36 -0
- package/dist/.dts7/build/merge-documentation.d.ts.map +1 -0
- package/dist/.dts7/build/ownership-model.d.ts +58 -0
- package/dist/.dts7/build/ownership-model.d.ts.map +1 -0
- package/dist/.dts7/build/parse.d.ts +206 -0
- package/dist/.dts7/build/parse.d.ts.map +1 -0
- package/dist/.dts7/build/reference-projections.d.ts +168 -0
- package/dist/.dts7/build/reference-projections.d.ts.map +1 -0
- package/dist/.dts7/build/resolution/resolve-import.d.ts +62 -0
- package/dist/.dts7/build/resolution/resolve-import.d.ts.map +1 -0
- package/dist/.dts7/build/resolution/resolve-package-schema.d.ts +83 -0
- package/dist/.dts7/build/resolution/resolve-package-schema.d.ts.map +1 -0
- package/dist/.dts7/build/resolution/resolve-tsconfig-paths.d.ts +18 -0
- package/dist/.dts7/build/resolution/resolve-tsconfig-paths.d.ts.map +1 -0
- package/dist/.dts7/build/resolution/resolve-within-root.d.ts +35 -0
- package/dist/.dts7/build/resolution/resolve-within-root.d.ts.map +1 -0
- package/dist/.dts7/build/sarif.d.ts +66 -0
- package/dist/.dts7/build/sarif.d.ts.map +1 -0
- package/dist/.dts7/build/scan-dependencies.d.ts +71 -0
- package/dist/.dts7/build/scan-dependencies.d.ts.map +1 -0
- package/dist/.dts7/build/sort-by-identity.d.ts +14 -0
- package/dist/.dts7/build/sort-by-identity.d.ts.map +1 -0
- package/dist/.dts7/build/source-position.d.ts +69 -0
- package/dist/.dts7/build/source-position.d.ts.map +1 -0
- package/dist/.dts7/build/tool-version.d.ts +8 -0
- package/dist/.dts7/build/tool-version.d.ts.map +1 -0
- package/dist/.dts7/build/types.d.ts +7 -0
- package/dist/.dts7/build/types.d.ts.map +1 -0
- package/dist/.dts7/build/typescript.d.ts +6 -0
- package/dist/.dts7/build/typescript.d.ts.map +1 -0
- package/dist/.dts7/build/usage-report.d.ts +124 -0
- package/dist/.dts7/build/usage-report.d.ts.map +1 -0
- package/dist/.dts7/cli/filesystem.d.ts +7 -0
- package/dist/.dts7/cli/filesystem.d.ts.map +1 -0
- package/dist/.dts7/eslint-plugin/glob.d.ts +7 -0
- package/dist/.dts7/eslint-plugin/glob.d.ts.map +1 -0
- package/dist/.dts7/eslint-plugin/index.d.ts +38 -0
- package/dist/.dts7/eslint-plugin/index.d.ts.map +1 -0
- package/dist/.dts7/eslint-plugin/no-node-fs.d.ts +15 -0
- package/dist/.dts7/eslint-plugin/no-node-fs.d.ts.map +1 -0
- package/dist/.dts7/eslint-plugin/no-raw-process-env.d.ts +23 -0
- package/dist/.dts7/eslint-plugin/no-raw-process-env.d.ts.map +1 -0
- package/dist/.dts7/evidence/define-projection.d.ts +51 -0
- package/dist/.dts7/evidence/define-projection.d.ts.map +1 -0
- package/dist/.dts7/evidence/index.d.ts +19 -0
- package/dist/.dts7/evidence/index.d.ts.map +1 -0
- package/dist/.dts7/helpers/index.d.ts +132 -0
- package/dist/.dts7/helpers/index.d.ts.map +1 -0
- package/dist/.dts7/helpers/processors.d.ts +32 -0
- package/dist/.dts7/helpers/processors.d.ts.map +1 -0
- package/dist/.dts7/helpers/validators.d.ts +68 -0
- package/dist/.dts7/helpers/validators.d.ts.map +1 -0
- package/dist/.dts7/node/index.d.ts +21 -0
- package/dist/.dts7/node/index.d.ts.map +1 -0
- package/dist/.dts7/runtime/cache.d.ts +17 -0
- package/dist/.dts7/runtime/cache.d.ts.map +1 -0
- package/dist/.dts7/runtime/create.d.ts +23 -0
- package/dist/.dts7/runtime/create.d.ts.map +1 -0
- package/dist/.dts7/runtime/document.d.ts +214 -0
- package/dist/.dts7/runtime/document.d.ts.map +1 -0
- package/dist/.dts7/runtime/errors.d.ts +55 -0
- package/dist/.dts7/runtime/errors.d.ts.map +1 -0
- package/dist/.dts7/runtime/index.d.ts +25 -0
- package/dist/.dts7/runtime/index.d.ts.map +1 -0
- package/dist/.dts7/runtime/registry.d.ts +12 -0
- package/dist/.dts7/runtime/registry.d.ts.map +1 -0
- package/dist/.dts7/runtime/reset.d.ts +8 -0
- package/dist/.dts7/runtime/reset.d.ts.map +1 -0
- package/dist/.dts7/runtime/types.d.ts +190 -0
- package/dist/.dts7/runtime/types.d.ts.map +1 -0
- package/dist/.dts7/runtime/validate.d.ts +27 -0
- package/dist/.dts7/runtime/validate.d.ts.map +1 -0
- package/dist/{build-6XFHJFQK.js → build-UEENZEUX.js} +43 -42
- package/dist/build-UEENZEUX.js.map +1 -0
- package/dist/build.cjs +42 -41
- package/dist/build.cjs.map +1 -1
- package/dist/build.js +42 -41
- package/dist/build.js.map +1 -1
- package/dist/build.ts7.d.cts +1 -0
- package/dist/build.ts7.d.ts +1 -0
- package/dist/{chunk-RL5KFVUT.js → chunk-TBL3O7IG.js} +2 -2
- package/dist/cli/index.js +29 -28
- package/dist/cli/index.js.map +1 -1
- package/dist/eslint-plugin/index.cjs.map +1 -1
- package/dist/eslint-plugin/index.js.map +1 -1
- package/dist/eslint-plugin/index.ts7.d.cts +1 -0
- package/dist/eslint-plugin/index.ts7.d.ts +1 -0
- package/dist/evidence.cjs +1 -1
- package/dist/evidence.cjs.map +1 -1
- package/dist/evidence.js +1 -1
- package/dist/evidence.js.map +1 -1
- package/dist/evidence.ts7.d.cts +1 -0
- package/dist/evidence.ts7.d.ts +1 -0
- package/dist/helpers.cjs +4 -4
- package/dist/helpers.cjs.map +1 -1
- package/dist/helpers.js +4 -4
- package/dist/helpers.js.map +1 -1
- package/dist/helpers.ts7.d.cts +1 -0
- package/dist/helpers.ts7.d.ts +1 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.ts7.d.cts +1 -0
- package/dist/index.ts7.d.ts +1 -0
- package/dist/node.ts7.d.cts +1 -0
- package/dist/node.ts7.d.ts +1 -0
- package/examples/README.md +46 -80
- package/package.json +43 -12
- package/schemas/contract-model.schema.json +7 -7
- package/schemas/env-cap-report.schema.json +88 -88
- package/skills/env-cap/SKILL.md +12 -13
- package/skills/env-cap/references/api.md +1 -1
- package/specs/architecture.md +147 -122
- package/specs/decisions/0001-runtime-documentation-separation.md +1 -1
- package/specs/decisions/0014-cross-package-schema-discovery.md +4 -1
- package/specs/decisions/0023-tsconfig-path-alias-resolution.md +4 -1
- package/specs/decisions/0049-typescript-7-scanner-uses-a-bundled-typescript-6.md +13 -8
- package/specs/generated-artifacts.md +91 -71
- package/specs/migrations/README.md +6 -6
- package/specs/migrations/from-centralized-schema.md +1 -1
- package/specs/migrations/from-t3-env.md +9 -9
- package/PROMPT.md +0 -89
- package/dist/build-6XFHJFQK.js.map +0 -1
- /package/dist/{chunk-RL5KFVUT.js.map → chunk-TBL3O7IG.js.map} +0 -0
|
@@ -48,7 +48,7 @@ TypeScript 6 (`typescript@^6`, installed under the alias `@typescript/old`) as a
|
|
|
48
48
|
|
|
49
49
|
- A developer on TypeScript 7 installs env-cap and runs `./build` with no extra configuration; `tsc`
|
|
50
50
|
stays TypeScript 7.
|
|
51
|
-
- Every install of this package now carries ~
|
|
51
|
+
- Every install of this package now carries ~24 MB unpacked (~5 MB packed) for the bundled compiler. It
|
|
52
52
|
is nested, so a TypeScript 6 consumer does not save it by deduplication. The runtime, helpers, evidence
|
|
53
53
|
and node entry points never load it, and the isolation check keeps it that way.
|
|
54
54
|
- Bundling is what keeps the consumer's `tsc` theirs. As an ordinary dependency, `@typescript/old`'s `tsc`
|
|
@@ -62,13 +62,18 @@ TypeScript 6 (`typescript@^6`, installed under the alias `@typescript/old`) as a
|
|
|
62
62
|
pinned by `^6.0.2`, is only reachable from the build entry, and exists to be removed once TypeScript 7.1's
|
|
63
63
|
API replaces it. A new TypeScript 6 patch needs a release of this package to reach consumers.
|
|
64
64
|
- On TypeScript 7, the scanner parses with TypeScript 6. TypeScript 7.0 is designed to match 6.0's
|
|
65
|
-
behavior, and
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
consumers who pass their own nodes into these Stable primitives, because two copies
|
|
71
|
-
`SyntaxKind` are distinct enums.
|
|
65
|
+
behavior, and `scripts/typescript-compat.mjs` (CI job `typescript-compat`) parses every committed
|
|
66
|
+
`env.schema.ts` fixture (the examples and the integration fixtures) under a 5, a 6 and a 7 root and
|
|
67
|
+
requires the three outputs to be byte-identical.
|
|
68
|
+
- The `./build` and `./evidence` declarations name TypeScript AST types from `typescript`, and
|
|
69
|
+
TypeScript 7's package exports none. Typing them from the bundled package for everyone would break
|
|
70
|
+
TypeScript 5/6 consumers who pass their own nodes into these Stable primitives, because two copies
|
|
71
|
+
of `SyntaxKind` are distinct enums. So the build emits a second declaration tree, `dist/.dts7`,
|
|
72
|
+
identical except that its compiler-API types come from the bundled `@typescript/typescript6`, and
|
|
73
|
+
`package.json` serves it only to TypeScript 7 through `types@>=7` export conditions (amended
|
|
74
|
+
2026-11-09; before this, a 7 consumer needed `skipLibCheck` for those two entry points). Under 7
|
|
75
|
+
there is no second `SyntaxKind` to clash with, and every entry point but `./eslint-plugin` (typed
|
|
76
|
+
through its `@typescript-eslint/utils` peer) type-checks with full library checking; `scripts/typescript-compat.mjs` asserts which condition answered under each root.
|
|
72
77
|
|
|
73
78
|
## Alternatives considered
|
|
74
79
|
|
|
@@ -1,26 +1,28 @@
|
|
|
1
1
|
# Generated artifacts: what `env-cap` produces, and what it deliberately doesn't
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
3
|
+
Check this page before assuming `env-cap` generates something it doesn't. It
|
|
4
|
+
is the canonical place for that check, for a human or an AI agent working in
|
|
5
|
+
this repository or a consuming project.
|
|
6
|
+
|
|
7
|
+
Every artifact below is produced by `generateEnvArtifacts()`. Nothing here is
|
|
8
|
+
generated by a separate, independently-derived pipeline. The `env-cap` CLI is
|
|
9
|
+
a thin wrapper for the manifest/evidence outputs only (see
|
|
10
|
+
[ADR 0046](decisions/0046-cli-restricted-to-runtime-and-evidence-output.md)).
|
|
11
|
+
The documentation catalog, `.env.example`, and the ownership report have no
|
|
12
|
+
CLI flag at all, only a direct `generateDocumentation()`/`generateUsageReport()`
|
|
13
|
+
call.
|
|
14
|
+
|
|
15
|
+
Concretely, `computeArtifacts` (the function both `generateEnvArtifacts` and
|
|
16
|
+
`checkArtifacts` share) runs one `assembleProject()` parse/link pass. It then
|
|
17
|
+
builds all seven canonical fact models (ADR 0024) from that single result.
|
|
18
|
+
Every artifact in this file is a projection of that same run's models, not a
|
|
17
19
|
second, independently-assembled source. `--evidence <path>` writes the
|
|
18
|
-
composed Evidence Model to disk directly, as JSON
|
|
19
|
-
the canonical artifact itself rather than only its Markdown projections.
|
|
20
|
+
composed Evidence Model to disk directly, as JSON. That serves a project that
|
|
21
|
+
wants the canonical artifact itself rather than only its Markdown projections.
|
|
20
22
|
|
|
21
23
|
**Every artifact in this table is evidence that can _support_ a review
|
|
22
|
-
process
|
|
23
|
-
|
|
24
|
+
process, never a compliance claim**. Such a process might be a security
|
|
25
|
+
review, a privacy review, or a platform audit. Static analysis of one repository cannot, by itself,
|
|
24
26
|
establish compliance with any external standard. Every rendered artifact
|
|
25
27
|
that carries this claim opens with the same disclaimer
|
|
26
28
|
(`evidenceDisclaimer()` in `generated-banner.ts`, byte-identical to
|
|
@@ -33,72 +35,90 @@ data-cap's own):
|
|
|
33
35
|
|
|
34
36
|
## Declared vs. proven vs. evidence
|
|
35
37
|
|
|
36
|
-
Every fact in every generated artifact is one of exactly three kinds
|
|
38
|
+
Every fact in every generated artifact is one of exactly three kinds. A
|
|
37
39
|
rendering function may never blend them or imply one is another:
|
|
38
40
|
|
|
39
|
-
- **Declared
|
|
40
|
-
`VariableDocs`/`ContractDocs
|
|
41
|
-
`expiresAt`, `refreshInstructions`, `setupInstructions`,
|
|
42
|
-
`deprecated`/`deprecatedReason`/`removeBy`, `renamedFrom`,
|
|
43
|
-
`legalBasis`, `retention`, `dataResidency`, `auditRequired`,
|
|
44
|
-
Presence is checked; correctness, adequacy, and enforcement are
|
|
45
|
-
claimed. A report may say a variable's retention policy is
|
|
46
|
-
never that it is _"sufficient"_ or _"enforced."_
|
|
47
|
-
- **Proven
|
|
48
|
-
declared variable is actually read anywhere in the scanned
|
|
49
|
-
|
|
50
|
-
contract (Dependency Model)
|
|
51
|
-
conflict between contracts
|
|
52
|
-
|
|
41
|
+
- **Declared**: metadata the author wrote via `documentEnv()`'s
|
|
42
|
+
`VariableDocs`/`ContractDocs`. The fields are `description`, `owner`,
|
|
43
|
+
`sensitivity`, `expiresAt`, `refreshInstructions`, `setupInstructions`,
|
|
44
|
+
`required`, `deprecated`/`deprecatedReason`/`removeBy`, `renamedFrom`,
|
|
45
|
+
`purpose`, `legalBasis`, `retention`, `dataResidency`, `auditRequired`,
|
|
46
|
+
`metadata`. Presence is checked; correctness, adequacy, and enforcement are
|
|
47
|
+
never claimed. A report may say a variable's retention policy is
|
|
48
|
+
_"documented,"_ never that it is _"sufficient"_ or _"enforced."_
|
|
49
|
+
- **Proven**: facts derived by AST analysis of the actual source. They cover:
|
|
50
|
+
- whether a declared variable is actually read anywhere in the scanned
|
|
51
|
+
surface (`UNCONSUMED_OWNED_VARIABLE`);
|
|
52
|
+
- which files import/reference a given contract (Dependency Model);
|
|
53
|
+
- every exclusive-group/compatibility conflict between contracts
|
|
54
|
+
(`FindingCode`'s compatibility family).
|
|
55
|
+
|
|
56
|
+
These are statically provable from the code that exists today, in this
|
|
53
57
|
repository, at analysis time.
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
58
|
+
|
|
59
|
+
- **A third case, named explicitly because it's neither**:
|
|
60
|
+
`VariableDocs.evidence.dynamicAccess`. It uses an ADR 0053-equivalent
|
|
61
|
+
citation mechanism, mirroring data-cap's identical design. It is declared,
|
|
62
|
+
like every other governance field. Unlike every other one, it's re-verified
|
|
63
|
+
every run against a persisted content hash of the cited file
|
|
59
64
|
(`MISSING_DYNAMIC_ACCESS_CITATION`/`STALE_DYNAMIC_ACCESS_CITATION`). A
|
|
60
65
|
passing check establishes only that the citation is currently _supported
|
|
61
|
-
by its own citation/integrity state_
|
|
62
|
-
visibly changed since the developer wrote it
|
|
63
|
-
access has been proven to happen there. No rendering of this
|
|
64
|
-
uses "verified" or "proven" language for this reason.
|
|
66
|
+
by its own citation/integrity state_. That means the cited file exists and
|
|
67
|
+
hasn't visibly changed since the developer wrote it. It never means the
|
|
68
|
+
described access has been proven to happen there. No rendering of this
|
|
69
|
+
field ever uses "verified" or "proven" language for this reason.
|
|
65
70
|
|
|
66
71
|
## Built in this release
|
|
67
72
|
|
|
68
|
-
| Artifact
|
|
69
|
-
|
|
|
70
|
-
| **Manifest** (`--location`)
|
|
71
|
-
| **Documentation catalog** (`generateDocumentation()
|
|
72
|
-
| **`.env.example`** (`generateDocumentation()`'s `envExample` option
|
|
73
|
-
| **Dependency & Ownership report** (`generateUsageReport()
|
|
74
|
-
| **Evidence Model** (`--evidence`, ADR 0038)
|
|
75
|
-
| **JSON report** (`--json`)
|
|
76
|
-
| **Drift check** (`--check`)
|
|
77
|
-
| **SARIF log**
|
|
73
|
+
| Artifact | Generator | What it answers |
|
|
74
|
+
| ------------------------------------------------------------------------------------------- | ---------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
75
|
+
| **Manifest** (`--location`) | `generateEnvManifest` (Contract Model) | A single, deterministic `.ts` file re-exporting every _active_ contract, projected from the Contract Model (not a second source of truth). `runtime/validate.ts` validates real `process.env` values against exactly this manifest. |
|
|
76
|
+
| **Documentation catalog** (`generateDocumentation()`, no CLI flag, ADR 0046) | `generateDocumentation` | Per-contract variables: `description` ("why") and `owner`/`sensitivity`/`purpose`/`legalBasis`/`retention`/`dataResidency` (labeled declared, not verified). It also has a live "expiring soon or already expired" section sourced from the Lifecycle Model. |
|
|
77
|
+
| **`.env.example`** (`generateDocumentation()`'s `envExample` option, no CLI flag, ADR 0046) | `generateDocumentation` | One line per active variable, generated from the same declared metadata the documentation catalog renders. It is never hand-maintained, and never a second copy of the schema to drift from the real one. |
|
|
78
|
+
| **Dependency & Ownership report** (`generateUsageReport()`, no CLI flag, ADR 0046) | `generateUsage` (Dependency + Ownership Model) | The owner → variables matrix, plus a real, in-repo, AST-proven consumer graph: which files actually read which variable, never guessed at. `UNCONSUMED_OWNED_VARIABLE`/`ABANDONED_CONTRACT` are warnings; `UNRESOLVED_CONSUMER`/`INDETERMINATE_OWNERSHIP` stay info, escalated only by `--strict-ownership`. |
|
|
79
|
+
| **Evidence Model** (`--evidence`, ADR 0038) | `generateEvidenceModel` | The composed `EvidenceModel` (ADR 0024's seventh model) as JSON, plus a paired `.fingerprint` sidecar, holding whichever Contract/Dependency/Ownership/Finding/Lifecycle/Change models were computed this run. It is always composed in memory; the flag only controls whether it's additionally written to disk. |
|
|
80
|
+
| **JSON report** (`--json`) | CLI (`src/cli/json.ts`) | The full result as one versioned envelope (`@maverickcer/env-cap/schema`): every finding, every generator's output, and the composed Evidence Model. A CI step or another tool can consume it without parsing human-readable text. |
|
|
81
|
+
| **Drift check** (`--check`) | `checkArtifacts` | Recomputes every requested artifact and diffs it against disk; it writes nothing and exits non-zero if anything is stale or missing. Its exit code reflects staleness only, independent of `--strict*` finding severity. |
|
|
82
|
+
| **SARIF log** | `buildSarifLog` (library export) | A SARIF 2.1.0 adapter over the Finding Model, for a security-tooling pipeline that already ingests SARIF. It is not CLI-wired. Whichever project needs it calls it directly, as an ordinary consumer of the public Finding Model type (the same boundary Phase 4/5's own generator scripts sit behind). |
|
|
83
|
+
|
|
84
|
+
## Standard-format documents
|
|
85
|
+
|
|
86
|
+
Generated from `docs/surface.json` by `internal-package-contract generate`; each row names the test that
|
|
87
|
+
checks the format, and generation fails if that test is gone.
|
|
88
|
+
|
|
89
|
+
<!-- ipc:begin standards -->
|
|
90
|
+
|
|
91
|
+
| Document | Standard | Produced by | Checked against | Test | Limits |
|
|
92
|
+
| -------- | ----------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | -------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
93
|
+
| Findings | OASIS SARIF 2.1.0 | `buildSarifLog` (`@maverickcer/env-cap/build`), over the Finding Model | The official OASIS schema (`test/fixtures/standards/`, a managed copy) | `test/build/sarif.test.ts` | A library export, not wired to the CLI. A finding carries a region only when it has a real position. A finding with a position points at the cited file (percent-encoded path); the rest carry a file but no line. |
|
|
94
|
+
|
|
95
|
+
<!-- ipc:end standards -->
|
|
78
96
|
|
|
79
97
|
## Canonical fact models (ADR 0024)
|
|
80
98
|
|
|
81
|
-
Seven canonical, versioned, JSON-serializable models
|
|
82
|
-
surface every rendered artifact above is a projection
|
|
83
|
-
`defineEvidenceProjection()` consumers (below) read instead of
|
|
84
|
-
facts from raw source.
|
|
99
|
+
Seven canonical, versioned, JSON-serializable models form the
|
|
100
|
+
machine-readable surface that every rendered artifact above is a projection
|
|
101
|
+
of. `defineEvidenceProjection()` consumers (below) read them instead of
|
|
102
|
+
re-deriving facts from raw source.
|
|
85
103
|
|
|
86
104
|
| Model | Builder | What it answers |
|
|
87
105
|
| ---------------- | ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
88
|
-
| Contract Model | `buildContractModel` | Every discovered contract (active or not) and its variables
|
|
89
|
-
| Dependency Model | `buildDependencyModel` | Every proven consumer relationship, indexed by contract/variable and by consuming file
|
|
106
|
+
| Contract Model | `buildContractModel` | Every discovered contract (active or not) and its variables: the schema shape itself, projected and sorted deterministically. |
|
|
107
|
+
| Dependency Model | `buildDependencyModel` | Every proven consumer relationship, indexed by contract/variable and by consuming file. It is the fact the ownership report projects, computed once. |
|
|
90
108
|
| Ownership Model | `buildOwnershipModel` | Every contract and variable's effective owner, plus first-class `unownedContracts`/`unownedVariables` arrays. |
|
|
91
|
-
| Finding Model | `buildFindingModel` | Every rule violation and derived risk signal, unified behind one shape with a stable `code` and a structured `EvidenceReference
|
|
109
|
+
| Finding Model | `buildFindingModel` | Every rule violation and derived risk signal, unified behind one shape with a stable `code` and a structured `EvidenceReference`. The SARIF adapter and Evidence Model compose from it. |
|
|
92
110
|
| Lifecycle Model | `buildLifecycleModel` | Every contract and variable's lifecycle data: expiry, deprecation, rename correlation. |
|
|
93
|
-
| Change Model | `buildChangeModel` | What changed since the last persisted evidence snapshot
|
|
94
|
-
| Evidence Model | `generateEvidenceModel` | The composition of the other six into one artifact
|
|
95
|
-
|
|
96
|
-
A first wave of reference projections ships alongside the models themselves
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
111
|
+
| Change Model | `buildChangeModel` | What changed since the last persisted evidence snapshot: the manifest diff, keyed for a "changes since last report" section. |
|
|
112
|
+
| Evidence Model | `generateEvidenceModel` | The composition of the other six into one artifact, which every reference projection below reads. Two of the seven are separately published as JSON Schema (`@maverickcer/env-cap/schema`, `@maverickcer/env-cap/schema/contract-model`); the rest are TypeScript-typed only, not yet independently schema'd. |
|
|
113
|
+
|
|
114
|
+
A first wave of reference projections ships alongside the models themselves:
|
|
115
|
+
|
|
116
|
+
- `configurationReference`, `ownershipSummary`, and `expiringSoonReport`, all
|
|
117
|
+
built through `defineEvidenceProjection()`;
|
|
118
|
+
- `buildSarifLog`, a SARIF 2.1.0 adapter over Finding Model.
|
|
119
|
+
|
|
120
|
+
Every one of these is an ordinary consumer of the public model types above.
|
|
121
|
+
None has a privileged internal path a downstream tool couldn't also use. A
|
|
122
|
+
future open-standard projection would be architecturally no different. It
|
|
123
|
+
would be another `defineEvidenceProjection()` consumer, not a bespoke script
|
|
124
|
+
bypassing this model.
|
|
@@ -10,12 +10,12 @@ Migration does not require replacing your validation approach immediately. The r
|
|
|
10
10
|
|
|
11
11
|
## Guides
|
|
12
12
|
|
|
13
|
-
- [From `dotenv`](from-dotenv.md)
|
|
14
|
-
- [From raw `process.env`](from-process-env.md)
|
|
15
|
-
- [From a centralized environment schema](from-centralized-schema.md)
|
|
16
|
-
- [From Zod](from-zod.md)
|
|
17
|
-
- [From envalid](from-envalid.md)
|
|
18
|
-
- [From t3-env](from-t3-env.md)
|
|
13
|
+
- [From `dotenv`](from-dotenv.md): keep `dotenv` loading values, add capability-owned contracts on top.
|
|
14
|
+
- [From raw `process.env`](from-process-env.md): replace scattered `process.env.X` access with owned, validated contracts.
|
|
15
|
+
- [From a centralized environment schema](from-centralized-schema.md): split a single `env.ts`/`env.schema.ts` file into capability-owned schemas.
|
|
16
|
+
- [From Zod](from-zod.md): keep Zod for validation, move ownership to capabilities.
|
|
17
|
+
- [From envalid](from-envalid.md): keep envalid's validators, move ownership to capabilities.
|
|
18
|
+
- [From t3-env](from-t3-env.md): keep t3-env's client/server split conceptually, replace the centralized object with capability-owned contracts.
|
|
19
19
|
|
|
20
20
|
## Migration strategy
|
|
21
21
|
|
|
@@ -22,7 +22,7 @@ export const env = createConfig({
|
|
|
22
22
|
});
|
|
23
23
|
```
|
|
24
24
|
|
|
25
|
-
Centralized schemas are a reasonable starting point. They provide a clear location for configuration and make small applications
|
|
25
|
+
Centralized schemas are a reasonable starting point. They provide a clear location for configuration and make small applications straightforward to understand.
|
|
26
26
|
|
|
27
27
|
As applications grow, however, the centralized file becomes a shared ownership boundary:
|
|
28
28
|
|
|
@@ -43,7 +43,7 @@ A centralized environment object is often the right choice when:
|
|
|
43
43
|
- one team owns the application
|
|
44
44
|
- configuration is relatively small
|
|
45
45
|
- all variables belong to the same deployment boundary
|
|
46
|
-
- a single application schema
|
|
46
|
+
- a single application schema stays maintainable
|
|
47
47
|
|
|
48
48
|
Example:
|
|
49
49
|
|
|
@@ -250,13 +250,13 @@ client.contract.ts
|
|
|
250
250
|
The application build decides which contracts are included.
|
|
251
251
|
|
|
252
252
|
This keeps the runtime small and avoids creating artificial package boundaries. This remains the
|
|
253
|
-
recommended default
|
|
254
|
-
client bundle
|
|
253
|
+
recommended default. It is also the only mechanism that actually keeps a server-only variable's source out
|
|
254
|
+
of a client bundle (see [ADR 0004](../decisions/0004-no-client-server-package-split.md)).
|
|
255
255
|
|
|
256
|
-
|
|
257
|
-
two contract files, `context`/`activeContexts`
|
|
258
|
-
contexts"](../../GUIDE.md#validation-contexts)
|
|
259
|
-
|
|
256
|
+
You may prefer to keep `server`/`client` variables declared in one schema location instead of splitting into
|
|
257
|
+
two contract files. In that case, `context`/`activeContexts` is the closer analogue to t3-env's
|
|
258
|
+
`server`/`client` grouping (see GUIDE.md's ["Validation contexts"](../../GUIDE.md#validation-contexts)
|
|
259
|
+
section and [ADR 0022](../decisions/0022-validation-contexts.md)):
|
|
260
260
|
|
|
261
261
|
```ts
|
|
262
262
|
createEnv({
|
|
@@ -273,7 +273,7 @@ await validateEnv({ manifest, values: window.__ENV__, activeContexts: ["client"]
|
|
|
273
273
|
```
|
|
274
274
|
|
|
275
275
|
This only controls whether `validateEnv()` processes a variable, not whether its definition ships to the
|
|
276
|
-
browser
|
|
276
|
+
browser. It's a convenience for teams that don't need a hard module boundary, not a substitute for one. If
|
|
277
277
|
`DATABASE_URL` must never appear in a client bundle at all, use the two-manifest approach above instead.
|
|
278
278
|
|
|
279
279
|
## Migrating a Next.js application
|
|
@@ -366,7 +366,7 @@ The runtime remains modular while platform teams still have a complete inventory
|
|
|
366
366
|
t3-env may remain the better choice when:
|
|
367
367
|
|
|
368
368
|
- your application has one configuration owner
|
|
369
|
-
- the centralized schema
|
|
369
|
+
- the centralized schema stays maintainable
|
|
370
370
|
- capability boundaries are not important
|
|
371
371
|
- documentation and lifecycle tracking are handled elsewhere
|
|
372
372
|
|
package/PROMPT.md
DELETED
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
## AI-Assisted Integration
|
|
2
|
-
|
|
3
|
-
env-cap is designed to integrate with existing application architectures rather than replace them blindly.
|
|
4
|
-
|
|
5
|
-
If you use an AI coding assistant, provide it with the following prompt before asking it to modify your project. This helps the assistant understand both your application's architecture and env-cap's design principles before making changes.
|
|
6
|
-
|
|
7
|
-
Replace `<YOUR_PROJECT_CONTEXT>` with any additional context about your application before submitting the prompt.
|
|
8
|
-
|
|
9
|
-
```text
|
|
10
|
-
You are integrating env-cap into an existing production codebase.
|
|
11
|
-
|
|
12
|
-
Package source:
|
|
13
|
-
https://github.com/maverickcer/env-cap
|
|
14
|
-
|
|
15
|
-
Before making any changes, first study the env-cap repository above, including:
|
|
16
|
-
|
|
17
|
-
- README.md
|
|
18
|
-
- Architecture documentation
|
|
19
|
-
- ADRs (architectural decision records)
|
|
20
|
-
- Examples
|
|
21
|
-
- Migration guides
|
|
22
|
-
- Package exports and API design
|
|
23
|
-
|
|
24
|
-
Understand the package's intended architecture and constraints before proposing an implementation.
|
|
25
|
-
|
|
26
|
-
Your role is to act as a senior/staff-level engineer performing an infrastructure integration review.
|
|
27
|
-
|
|
28
|
-
Application context:
|
|
29
|
-
<YOUR_PROJECT_CONTEXT>
|
|
30
|
-
|
|
31
|
-
First, analyze this repository and understand:
|
|
32
|
-
|
|
33
|
-
1. Application architecture:
|
|
34
|
-
- Framework and runtime(s)
|
|
35
|
-
- Build system and bundler behavior
|
|
36
|
-
- Monorepo/package boundaries (if applicable)
|
|
37
|
-
- Server/client boundaries
|
|
38
|
-
- Deployment environments
|
|
39
|
-
- CI/CD environment configuration
|
|
40
|
-
- Existing environment loading and validation flow
|
|
41
|
-
|
|
42
|
-
2. Current configuration system:
|
|
43
|
-
- Where environment variables are defined
|
|
44
|
-
- Where they are consumed
|
|
45
|
-
- Existing validation logic
|
|
46
|
-
- Existing documentation or generated configuration artifacts
|
|
47
|
-
- Security-sensitive variables
|
|
48
|
-
- Client-exposed variables
|
|
49
|
-
|
|
50
|
-
3. Integration approach:
|
|
51
|
-
- Determine where env-cap contracts should live
|
|
52
|
-
- Identify existing environment boundaries
|
|
53
|
-
- Determine whether validation contexts are appropriate
|
|
54
|
-
- Determine whether separate manifests/contracts are needed
|
|
55
|
-
- Identify migration risks
|
|
56
|
-
|
|
57
|
-
Follow env-cap's architectural principles:
|
|
58
|
-
|
|
59
|
-
- Runtime validation and build-time analysis are separate concerns.
|
|
60
|
-
- Generated artifacts are derived outputs, not manually maintained files.
|
|
61
|
-
- Server-only secrets must remain outside client bundles.
|
|
62
|
-
- Validation contexts control validation participation only; they are not a security boundary.
|
|
63
|
-
- Application code determines active validation contexts explicitly.
|
|
64
|
-
- Do not add framework-specific behavior to env-cap usage.
|
|
65
|
-
- Avoid unnecessary wrappers or abstractions unless they solve a real application need.
|
|
66
|
-
|
|
67
|
-
Before changing code, provide:
|
|
68
|
-
|
|
69
|
-
1. Current environment configuration architecture summary.
|
|
70
|
-
2. Recommended env-cap integration strategy.
|
|
71
|
-
3. Proposed migration steps.
|
|
72
|
-
4. Files that should change.
|
|
73
|
-
5. Risks and mitigations.
|
|
74
|
-
6. Questions requiring developer decisions.
|
|
75
|
-
|
|
76
|
-
Do not implement changes until the plan has been reviewed and approved.
|
|
77
|
-
|
|
78
|
-
After approval:
|
|
79
|
-
|
|
80
|
-
- Implement changes incrementally.
|
|
81
|
-
- Preserve existing behavior where possible.
|
|
82
|
-
- Add or update tests.
|
|
83
|
-
- Verify generated documentation/artifacts.
|
|
84
|
-
- Verify type safety.
|
|
85
|
-
- Verify build output.
|
|
86
|
-
- Verify CI/CD compatibility.
|
|
87
|
-
|
|
88
|
-
For the best results, provide your AI assistant access to both your repository and the env-cap repository. The assistant should understand your application's architecture before recommending how env-cap fits into it.
|
|
89
|
-
```
|