kibi-cli 2.2.0 → 2.4.0
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/dist/cli-json-command.d.ts.map +1 -1
- package/dist/cli-json-command.js +2 -2
- package/dist/cli-operation-loader.d.ts.map +1 -1
- package/dist/cli-operation-loader.js +3 -0
- package/dist/cli-operation-metadata.d.ts +5 -1
- package/dist/cli-operation-metadata.d.ts.map +1 -1
- package/dist/cli-operation-metadata.js +6 -1
- package/dist/cli-register-maintenance.d.ts.map +1 -1
- package/dist/cli-register-maintenance.js +7 -0
- package/dist/cli-register-reporting.d.ts.map +1 -1
- package/dist/cli-register-reporting.js +4 -0
- package/dist/commands/check-diff.d.ts +5 -0
- package/dist/commands/check-diff.d.ts.map +1 -0
- package/dist/commands/check-diff.js +62 -0
- package/dist/commands/check-generated.d.ts.map +1 -1
- package/dist/commands/check-generated.js +41 -18
- package/dist/commands/check.d.ts.map +1 -1
- package/dist/commands/check.js +210 -73
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/doctor.js +63 -29
- package/dist/commands/github-init.d.ts.map +1 -1
- package/dist/commands/github-init.js +9 -2
- package/dist/commands/merge-driver.d.ts +31 -0
- package/dist/commands/merge-driver.d.ts.map +1 -0
- package/dist/commands/merge-driver.js +268 -0
- package/dist/commands/sync/manifest.d.ts.map +1 -1
- package/dist/commands/sync/manifest.js +3 -1
- package/dist/engine.d.ts +15 -1
- package/dist/engine.d.ts.map +1 -1
- package/dist/engine.js +252 -52
- package/dist/extractors/symbols-coordinator.d.ts +7 -0
- package/dist/extractors/symbols-coordinator.d.ts.map +1 -1
- package/dist/extractors/symbols-coordinator.js +75 -39
- package/dist/operations/bootstrap/candidates.js +1 -1
- package/dist/operations/bootstrap/discovery.js +1 -1
- package/dist/operations/bootstrap/generate.d.ts.map +1 -1
- package/dist/operations/bootstrap/generate.js +21 -5
- package/dist/operations/bootstrap/guidance-actions.d.ts.map +1 -1
- package/dist/operations/bootstrap/guidance-actions.js +3 -0
- package/dist/operations/bootstrap/guidance.d.ts.map +1 -1
- package/dist/operations/bootstrap/guidance.js +7 -1
- package/dist/operations/bootstrap/intent-claims.d.ts +17 -0
- package/dist/operations/bootstrap/intent-claims.d.ts.map +1 -0
- package/dist/operations/bootstrap/intent-claims.js +95 -0
- package/dist/operations/bootstrap/presentation.d.ts +2 -0
- package/dist/operations/bootstrap/presentation.d.ts.map +1 -1
- package/dist/operations/bootstrap/presentation.js +60 -1
- package/dist/operations/bootstrap/types.d.ts +28 -0
- package/dist/operations/bootstrap/types.d.ts.map +1 -1
- package/dist/operations/bootstrap/types.js +16 -0
- package/dist/operations/modeling/predicate-inference-1.js +1 -1
- package/dist/operations/mutation/source-authoring.d.ts.map +1 -1
- package/dist/operations/mutation/source-authoring.js +175 -53
- package/dist/operations/mutation/symbol-refresh.d.ts.map +1 -1
- package/dist/operations/mutation/symbol-refresh.js +4 -1
- package/dist/operations/mutation/upsert.d.ts.map +1 -1
- package/dist/operations/mutation/upsert.js +5 -7
- package/dist/operations/planning/apply-plan.d.ts.map +1 -1
- package/dist/operations/planning/apply-plan.js +5 -9
- package/dist/operations/proof/ingest-proof.d.ts.map +1 -1
- package/dist/operations/proof/ingest-proof.js +1 -0
- package/dist/operations/semantic-advisor/analysis-receipt.d.ts.map +1 -1
- package/dist/operations/semantic-advisor/analysis-receipt.js +7 -1
- package/dist/operations/semantic-advisor/analyze-prose.d.ts.map +1 -1
- package/dist/operations/semantic-advisor/analyze-prose.js +26 -4
- package/dist/operations/semantic-advisor/clauses.d.ts +1 -0
- package/dist/operations/semantic-advisor/clauses.d.ts.map +1 -1
- package/dist/operations/semantic-advisor/clauses.js +7 -1
- package/dist/performance-trace.d.ts +17 -0
- package/dist/performance-trace.d.ts.map +1 -0
- package/dist/performance-trace.js +134 -0
- package/dist/plugins/approved-source-analyzers.d.ts +13 -0
- package/dist/plugins/approved-source-analyzers.d.ts.map +1 -0
- package/dist/plugins/approved-source-analyzers.generated.d.ts +71 -0
- package/dist/plugins/approved-source-analyzers.generated.d.ts.map +1 -0
- package/dist/plugins/approved-source-analyzers.generated.js +77 -0
- package/dist/plugins/approved-source-analyzers.js +3 -0
- package/dist/plugins/maintenance-source-analysis.d.ts +14 -0
- package/dist/plugins/maintenance-source-analysis.d.ts.map +1 -0
- package/dist/plugins/maintenance-source-analysis.js +191 -0
- package/dist/plugins/registry.d.ts +2 -1
- package/dist/plugins/registry.d.ts.map +1 -1
- package/dist/plugins/registry.js +6 -1
- package/dist/plugins/source-analysis-service.d.ts +36 -1
- package/dist/plugins/source-analysis-service.d.ts.map +1 -1
- package/dist/plugins/source-analysis-service.js +184 -27
- package/dist/plugins/source-change-analysis.d.ts +15 -0
- package/dist/plugins/source-change-analysis.d.ts.map +1 -0
- package/dist/plugins/source-change-analysis.js +54 -0
- package/dist/plugins/source-classification.d.ts +41 -0
- package/dist/plugins/source-classification.d.ts.map +1 -0
- package/dist/plugins/source-classification.js +490 -0
- package/dist/prolog/swipl-resolver.d.ts +88 -0
- package/dist/prolog/swipl-resolver.d.ts.map +1 -0
- package/dist/prolog/swipl-resolver.js +446 -0
- package/dist/prolog.d.ts +15 -1
- package/dist/prolog.d.ts.map +1 -1
- package/dist/prolog.js +67 -6
- package/dist/public/diagnostic-usage.d.ts +14 -0
- package/dist/public/diagnostic-usage.d.ts.map +1 -1
- package/dist/public/diagnostic-usage.js +55 -1
- package/dist/public/impact/analyzer.d.ts.map +1 -1
- package/dist/public/impact/analyzer.js +56 -5
- package/dist/public/impact/diagnostics.d.ts.map +1 -1
- package/dist/public/impact/diagnostics.js +3 -1
- package/dist/public/impact/manifest.d.ts.map +1 -1
- package/dist/public/impact/manifest.js +15 -1
- package/dist/public/impact/source-changes.d.ts.map +1 -1
- package/dist/public/impact/source-changes.js +35 -27
- package/dist/public/impact/types.d.ts +2 -0
- package/dist/public/impact/types.d.ts.map +1 -1
- package/dist/public/operations/catalog.d.ts +117 -1
- package/dist/public/operations/catalog.d.ts.map +1 -1
- package/dist/public/operations/catalog.js +2 -0
- package/dist/public/operations/contracts.d.ts.map +1 -1
- package/dist/public/operations/contracts.js +309 -8
- package/dist/public/operations/impact-review-preparation.d.ts +14 -0
- package/dist/public/operations/impact-review-preparation.d.ts.map +1 -0
- package/dist/public/operations/impact-review-preparation.js +379 -0
- package/dist/public/operations/index.d.ts +2 -0
- package/dist/public/operations/index.d.ts.map +1 -1
- package/dist/public/operations/index.js +2 -0
- package/dist/public/operations/node-ports.d.ts.map +1 -1
- package/dist/public/operations/node-ports.js +1 -35
- package/dist/public/operations/proof-receipt-projection.d.ts +5 -0
- package/dist/public/operations/proof-receipt-projection.d.ts.map +1 -0
- package/dist/public/operations/proof-receipt-projection.js +36 -0
- package/dist/public/operations/specs/bootstrap.d.ts +73 -1
- package/dist/public/operations/specs/bootstrap.d.ts.map +1 -1
- package/dist/public/operations/specs/bootstrap.js +66 -1
- package/dist/public/operations/specs/impact-review-preparation.d.ts +47 -0
- package/dist/public/operations/specs/impact-review-preparation.d.ts.map +1 -0
- package/dist/public/operations/specs/impact-review-preparation.js +43 -0
- package/dist/public/operations/symbol-repair-plan.d.ts.map +1 -1
- package/dist/public/operations/symbol-repair-plan.js +3 -1
- package/dist/public/operations/types.d.ts +1 -1
- package/dist/public/operations/types.d.ts.map +1 -1
- package/dist/public/skills/kibi-bootstrap/SKILL.md +47 -11
- package/dist/public/skills/kibi-bootstrap/resources/bootstrap.md +6 -1
- package/dist/public/skills/kibi-usage/SKILL.md +14 -0
- package/dist/public/skills/kibi-usage/resources/operation-access.md +5 -0
- package/dist/public/telemetry-acceptance.d.ts +8 -0
- package/dist/public/telemetry-acceptance.d.ts.map +1 -1
- package/dist/public/telemetry-acceptance.js +10 -0
- package/dist/traceability/analysis-gate.d.ts +39 -0
- package/dist/traceability/analysis-gate.d.ts.map +1 -0
- package/dist/traceability/analysis-gate.js +51 -0
- package/dist/traceability/git-change-snapshot.d.ts +27 -0
- package/dist/traceability/git-change-snapshot.d.ts.map +1 -0
- package/dist/traceability/git-change-snapshot.js +411 -0
- package/dist/traceability/git-staged.d.ts +5 -1
- package/dist/traceability/git-staged.d.ts.map +1 -1
- package/dist/traceability/git-staged.js +16 -11
- package/dist/traceability/impact-evaluator.d.ts +54 -0
- package/dist/traceability/impact-evaluator.d.ts.map +1 -0
- package/dist/traceability/impact-evaluator.js +270 -0
- package/dist/traceability/impact-git-tree.d.ts +12 -0
- package/dist/traceability/impact-git-tree.d.ts.map +1 -0
- package/dist/traceability/impact-git-tree.js +46 -0
- package/dist/traceability/impact-knowledge.d.ts +16 -0
- package/dist/traceability/impact-knowledge.d.ts.map +1 -0
- package/dist/traceability/impact-knowledge.js +165 -0
- package/dist/traceability/impact-policy.d.ts +15 -0
- package/dist/traceability/impact-policy.d.ts.map +1 -0
- package/dist/traceability/impact-policy.js +48 -0
- package/dist/traceability/impact-policy.v1.schema.json +48 -0
- package/dist/traceability/impact-pr-diff.d.ts +5 -0
- package/dist/traceability/impact-pr-diff.d.ts.map +1 -0
- package/dist/traceability/impact-pr-diff.js +83 -0
- package/dist/traceability/impact-record-validation.d.ts +9 -0
- package/dist/traceability/impact-record-validation.d.ts.map +1 -0
- package/dist/traceability/impact-record-validation.js +113 -0
- package/dist/traceability/impact-review.d.ts +148 -0
- package/dist/traceability/impact-review.d.ts.map +1 -0
- package/dist/traceability/impact-review.js +494 -0
- package/dist/traceability/impact-review.schema.json +365 -0
- package/dist/traceability/impact-side-evidence.d.ts +13 -0
- package/dist/traceability/impact-side-evidence.d.ts.map +1 -0
- package/dist/traceability/impact-side-evidence.js +240 -0
- package/dist/traceability/reviewed-coordinate-refresh.d.ts +10 -0
- package/dist/traceability/reviewed-coordinate-refresh.d.ts.map +1 -0
- package/dist/traceability/reviewed-coordinate-refresh.js +49 -0
- package/dist/traceability/snapshot-knowledge.d.ts +4 -0
- package/dist/traceability/snapshot-knowledge.d.ts.map +1 -0
- package/dist/traceability/snapshot-knowledge.js +98 -0
- package/dist/traceability/staged-file-coverage.d.ts +23 -0
- package/dist/traceability/staged-file-coverage.d.ts.map +1 -1
- package/dist/traceability/staged-impact-contract.d.ts.map +1 -1
- package/dist/traceability/staged-impact-contract.js +2 -16
- package/dist/traceability/staged-symbols-manifest.d.ts +4 -0
- package/dist/traceability/staged-symbols-manifest.d.ts.map +1 -1
- package/dist/traceability/staged-symbols-manifest.js +17 -6
- package/dist/traceability/symbol-extract.d.ts +3 -5
- package/dist/traceability/symbol-extract.d.ts.map +1 -1
- package/dist/traceability/symbol-extract.js +49 -34
- package/dist/traceability/temp-kb.d.ts +1 -1
- package/dist/traceability/temp-kb.d.ts.map +1 -1
- package/dist/traceability/temp-kb.js +49 -13
- package/dist/traceability/trusted-pr-event.d.ts +13 -0
- package/dist/traceability/trusted-pr-event.d.ts.map +1 -0
- package/dist/traceability/trusted-pr-event.js +105 -0
- package/dist/utils/canonical-path.d.ts +3 -0
- package/dist/utils/canonical-path.d.ts.map +1 -0
- package/dist/utils/canonical-path.js +33 -0
- package/package.json +14 -5
- package/src/public/diagnostic-usage.ts +59 -1
- package/src/public/impact/analyzer.ts +88 -5
- package/src/public/impact/diagnostics.ts +7 -5
- package/src/public/impact/manifest.ts +14 -1
- package/src/public/impact/source-changes.ts +39 -34
- package/src/public/impact/types.ts +5 -0
- package/src/public/operations/catalog.ts +2 -0
- package/src/public/operations/contracts.ts +385 -9
- package/src/public/operations/impact-review-preparation.ts +548 -0
- package/src/public/operations/index.ts +2 -0
- package/src/public/operations/node-ports.ts +1 -39
- package/src/public/operations/proof-receipt-projection.ts +39 -0
- package/src/public/operations/specs/bootstrap.ts +78 -4
- package/src/public/operations/specs/impact-review-preparation.ts +46 -0
- package/src/public/operations/symbol-repair-plan.ts +3 -1
- package/src/public/operations/types.ts +1 -0
- package/src/public/skills/kibi-bootstrap/SKILL.md +47 -11
- package/src/public/skills/kibi-bootstrap/resources/bootstrap.md +6 -1
- package/src/public/skills/kibi-usage/SKILL.md +14 -0
- package/src/public/skills/kibi-usage/resources/operation-access.md +5 -0
- package/src/public/telemetry-acceptance.ts +9 -0
- package/src/traceability/impact-policy.v1.schema.json +48 -0
- package/src/traceability/impact-review.schema.json +365 -0
- package/templates/github/kibi-badge.yml +0 -4
- package/templates/github/kibi-report.yml +0 -4
|
@@ -0,0 +1,490 @@
|
|
|
1
|
+
const MAX_SHEBANG_LENGTH = 512;
|
|
2
|
+
const MAX_SHEBANG_TOKENS = 16;
|
|
3
|
+
const MAX_TOKEN_LENGTH = 128;
|
|
4
|
+
const EXTENSIONS = {
|
|
5
|
+
".bash": { kind: "language", language: "bash" },
|
|
6
|
+
".c": { kind: "language", language: "c" },
|
|
7
|
+
".cc": { kind: "language", language: "cpp" },
|
|
8
|
+
".cjs": { kind: "language", language: "javascript" },
|
|
9
|
+
".cpp": { kind: "language", language: "cpp" },
|
|
10
|
+
".cs": { kind: "language", language: "csharp" },
|
|
11
|
+
".cts": { kind: "language", language: "typescript" },
|
|
12
|
+
".cxx": { kind: "language", language: "cpp" },
|
|
13
|
+
".go": { kind: "language", language: "go" },
|
|
14
|
+
".h": { kind: "ambiguous", language: "c-or-cpp", candidates: ["c", "cpp"] },
|
|
15
|
+
".hcl": { kind: "language", language: "hcl" },
|
|
16
|
+
".hh": { kind: "language", language: "cpp" },
|
|
17
|
+
".hpp": { kind: "language", language: "cpp" },
|
|
18
|
+
".hxx": { kind: "language", language: "cpp" },
|
|
19
|
+
".html": {
|
|
20
|
+
kind: "file-level",
|
|
21
|
+
language: "html",
|
|
22
|
+
reason: "HTML is classified as a file-level document.",
|
|
23
|
+
},
|
|
24
|
+
".java": { kind: "language", language: "java" },
|
|
25
|
+
".js": { kind: "language", language: "javascript" },
|
|
26
|
+
".jsx": { kind: "language", language: "javascript" },
|
|
27
|
+
".json": {
|
|
28
|
+
kind: "file-level",
|
|
29
|
+
language: "json",
|
|
30
|
+
reason: "JSON is classified as a file-level document.",
|
|
31
|
+
},
|
|
32
|
+
".kt": { kind: "language", language: "kotlin" },
|
|
33
|
+
".mjs": { kind: "language", language: "javascript" },
|
|
34
|
+
".mts": { kind: "language", language: "typescript" },
|
|
35
|
+
".php": { kind: "language", language: "php" },
|
|
36
|
+
".pl": {
|
|
37
|
+
kind: "ambiguous",
|
|
38
|
+
language: "perl-or-prolog",
|
|
39
|
+
candidates: ["perl", "prolog"],
|
|
40
|
+
},
|
|
41
|
+
".py": { kind: "language", language: "python" },
|
|
42
|
+
".pyi": { kind: "language", language: "python" },
|
|
43
|
+
".rb": { kind: "language", language: "ruby" },
|
|
44
|
+
".rs": { kind: "language", language: "rust" },
|
|
45
|
+
".sh": {
|
|
46
|
+
kind: "file-level",
|
|
47
|
+
language: "shell",
|
|
48
|
+
reason: "A .sh extension does not identify a shell dialect.",
|
|
49
|
+
},
|
|
50
|
+
".sql": {
|
|
51
|
+
kind: "file-level",
|
|
52
|
+
language: "sql",
|
|
53
|
+
reason: "SQL is classified as a file-level document.",
|
|
54
|
+
},
|
|
55
|
+
".swift": { kind: "language", language: "swift" },
|
|
56
|
+
".ts": { kind: "language", language: "typescript" },
|
|
57
|
+
".tsx": { kind: "language", language: "typescript" },
|
|
58
|
+
".tf": { kind: "language", language: "terraform" },
|
|
59
|
+
".yaml": {
|
|
60
|
+
kind: "file-level",
|
|
61
|
+
language: "yaml",
|
|
62
|
+
reason: "YAML is classified as a file-level document.",
|
|
63
|
+
},
|
|
64
|
+
".yml": {
|
|
65
|
+
kind: "file-level",
|
|
66
|
+
language: "yaml",
|
|
67
|
+
reason: "YAML is classified as a file-level document.",
|
|
68
|
+
},
|
|
69
|
+
".css": {
|
|
70
|
+
kind: "file-level",
|
|
71
|
+
language: "css",
|
|
72
|
+
reason: "CSS is classified as a file-level document.",
|
|
73
|
+
},
|
|
74
|
+
};
|
|
75
|
+
/** Languages whose declarations the host analyzes with a qualified parser. */
|
|
76
|
+
const QUALIFIED_SOURCE_LANGUAGES = new Set([
|
|
77
|
+
"typescript",
|
|
78
|
+
"javascript",
|
|
79
|
+
"python",
|
|
80
|
+
"go",
|
|
81
|
+
"rust",
|
|
82
|
+
]);
|
|
83
|
+
/**
|
|
84
|
+
* Extension-only language label for a path, or "unknown". This is the single
|
|
85
|
+
* extension table; callers that need content-aware classification (shebangs,
|
|
86
|
+
* explicit hints, ambiguity) must use classifySource instead.
|
|
87
|
+
*/
|
|
88
|
+
// implements REQ-source-analysis-v2
|
|
89
|
+
export function extensionLanguage(filePath) {
|
|
90
|
+
return EXTENSIONS[extensionOf(filePath)]?.language ?? "unknown";
|
|
91
|
+
}
|
|
92
|
+
/** True for TypeScript/JavaScript paths handled by the ts-morph analyzer. */
|
|
93
|
+
// implements REQ-source-analysis-v2
|
|
94
|
+
export function isTsJsSourcePath(filePath) {
|
|
95
|
+
const language = extensionLanguage(filePath);
|
|
96
|
+
return language === "typescript" || language === "javascript";
|
|
97
|
+
}
|
|
98
|
+
/** True for paths whose language has qualified declaration analysis. */
|
|
99
|
+
// implements REQ-source-analysis-v2
|
|
100
|
+
export function isQualifiedSourcePath(filePath) {
|
|
101
|
+
const signal = EXTENSIONS[extensionOf(filePath)];
|
|
102
|
+
return (signal?.kind === "language" &&
|
|
103
|
+
QUALIFIED_SOURCE_LANGUAGES.has(signal.language));
|
|
104
|
+
}
|
|
105
|
+
/** Every classified extension, for parity checks against provider catalogs. */
|
|
106
|
+
// implements REQ-source-analysis-v2
|
|
107
|
+
export function classifiedExtensions() {
|
|
108
|
+
return Object.keys(EXTENSIONS).sort();
|
|
109
|
+
}
|
|
110
|
+
const FILE_LEVEL_LANGUAGES = new Set([
|
|
111
|
+
"css",
|
|
112
|
+
"html",
|
|
113
|
+
"json",
|
|
114
|
+
"perl",
|
|
115
|
+
"prolog",
|
|
116
|
+
"shell",
|
|
117
|
+
"sql",
|
|
118
|
+
"yaml",
|
|
119
|
+
]);
|
|
120
|
+
const SHELL_INTERPRETERS = new Set([
|
|
121
|
+
"ash",
|
|
122
|
+
"busybox",
|
|
123
|
+
"csh",
|
|
124
|
+
"dash",
|
|
125
|
+
"fish",
|
|
126
|
+
"ksh",
|
|
127
|
+
"mksh",
|
|
128
|
+
"pwsh",
|
|
129
|
+
"sh",
|
|
130
|
+
"tcsh",
|
|
131
|
+
"yash",
|
|
132
|
+
"zsh",
|
|
133
|
+
]);
|
|
134
|
+
function basename(value) {
|
|
135
|
+
return value.split(/[\\/]/).at(-1) ?? value;
|
|
136
|
+
}
|
|
137
|
+
function extensionOf(filePath) {
|
|
138
|
+
const name = basename(filePath);
|
|
139
|
+
const dot = name.lastIndexOf(".");
|
|
140
|
+
return dot <= 0 ? "" : name.slice(dot).toLowerCase();
|
|
141
|
+
}
|
|
142
|
+
function canonicalLanguage(value) {
|
|
143
|
+
const language = value.trim().toLowerCase();
|
|
144
|
+
if (language === "")
|
|
145
|
+
return undefined;
|
|
146
|
+
if (["py", "python", "python2", "python3"].includes(language))
|
|
147
|
+
return "python";
|
|
148
|
+
if (["bash", "bash5"].includes(language))
|
|
149
|
+
return "bash";
|
|
150
|
+
if (["rb", "ruby"].includes(language) || /^ruby\d+(?:\.\d+)*$/.test(language))
|
|
151
|
+
return "ruby";
|
|
152
|
+
if (["js", "javascript", "node", "nodejs"].includes(language))
|
|
153
|
+
return "javascript";
|
|
154
|
+
if (["ts", "typescript"].includes(language))
|
|
155
|
+
return "typescript";
|
|
156
|
+
if (["c++", "cpp", "cxx"].includes(language))
|
|
157
|
+
return "cpp";
|
|
158
|
+
if (["c#", "c-sharp", "csharp", "cs"].includes(language))
|
|
159
|
+
return "csharp";
|
|
160
|
+
if (["perl", "pl"].includes(language))
|
|
161
|
+
return "perl";
|
|
162
|
+
if (["prolog", "swipl"].includes(language))
|
|
163
|
+
return "prolog";
|
|
164
|
+
if (language === "tf")
|
|
165
|
+
return "terraform";
|
|
166
|
+
return language;
|
|
167
|
+
}
|
|
168
|
+
function tokenizeWords(value) {
|
|
169
|
+
const words = [];
|
|
170
|
+
let current = "";
|
|
171
|
+
let quote;
|
|
172
|
+
let escaped = false;
|
|
173
|
+
let started = false;
|
|
174
|
+
for (const character of value) {
|
|
175
|
+
if (escaped) {
|
|
176
|
+
current += character;
|
|
177
|
+
escaped = false;
|
|
178
|
+
started = true;
|
|
179
|
+
continue;
|
|
180
|
+
}
|
|
181
|
+
if (character === "\\" && quote !== "'") {
|
|
182
|
+
escaped = true;
|
|
183
|
+
started = true;
|
|
184
|
+
continue;
|
|
185
|
+
}
|
|
186
|
+
if (quote !== undefined) {
|
|
187
|
+
if (character === quote)
|
|
188
|
+
quote = undefined;
|
|
189
|
+
else
|
|
190
|
+
current += character;
|
|
191
|
+
started = true;
|
|
192
|
+
continue;
|
|
193
|
+
}
|
|
194
|
+
if (character === "'" || character === '"') {
|
|
195
|
+
quote = character;
|
|
196
|
+
started = true;
|
|
197
|
+
continue;
|
|
198
|
+
}
|
|
199
|
+
if (/\s/.test(character)) {
|
|
200
|
+
if (started) {
|
|
201
|
+
words.push(current);
|
|
202
|
+
if (words.length > MAX_SHEBANG_TOKENS)
|
|
203
|
+
return undefined;
|
|
204
|
+
current = "";
|
|
205
|
+
started = false;
|
|
206
|
+
}
|
|
207
|
+
continue;
|
|
208
|
+
}
|
|
209
|
+
current += character;
|
|
210
|
+
started = true;
|
|
211
|
+
if (current.length > MAX_TOKEN_LENGTH)
|
|
212
|
+
return undefined;
|
|
213
|
+
}
|
|
214
|
+
if (escaped || quote !== undefined)
|
|
215
|
+
return undefined;
|
|
216
|
+
if (started)
|
|
217
|
+
words.push(current);
|
|
218
|
+
return words.length > MAX_SHEBANG_TOKENS ? undefined : words;
|
|
219
|
+
}
|
|
220
|
+
function envCommand(arguments_) {
|
|
221
|
+
for (let index = 0; index < arguments_.length; index += 1) {
|
|
222
|
+
const argument = arguments_[index];
|
|
223
|
+
if (argument === undefined)
|
|
224
|
+
return undefined;
|
|
225
|
+
if (argument === "--")
|
|
226
|
+
return arguments_[index + 1];
|
|
227
|
+
if (argument === "-S" || argument === "--split-string") {
|
|
228
|
+
const commandText = arguments_.slice(index + 1).join(" ");
|
|
229
|
+
return commandInSplitString(commandText);
|
|
230
|
+
}
|
|
231
|
+
if (argument.startsWith("--split-string=")) {
|
|
232
|
+
return commandInSplitString(argument.slice("--split-string=".length));
|
|
233
|
+
}
|
|
234
|
+
if (argument === "-u" ||
|
|
235
|
+
argument === "--unset" ||
|
|
236
|
+
argument === "-C" ||
|
|
237
|
+
argument === "--chdir" ||
|
|
238
|
+
argument === "-a" ||
|
|
239
|
+
argument === "--argv0") {
|
|
240
|
+
index += 1;
|
|
241
|
+
continue;
|
|
242
|
+
}
|
|
243
|
+
if (argument === "-i" ||
|
|
244
|
+
argument === "--ignore-environment" ||
|
|
245
|
+
argument.startsWith("--unset=") ||
|
|
246
|
+
argument.startsWith("--chdir=") ||
|
|
247
|
+
argument.startsWith("--argv0=") ||
|
|
248
|
+
/^[A-Za-z_][A-Za-z0-9_]*=/.test(argument)) {
|
|
249
|
+
continue;
|
|
250
|
+
}
|
|
251
|
+
if (argument.startsWith("-"))
|
|
252
|
+
return undefined;
|
|
253
|
+
return argument;
|
|
254
|
+
}
|
|
255
|
+
return undefined;
|
|
256
|
+
}
|
|
257
|
+
function commandInSplitString(value) {
|
|
258
|
+
const words = tokenizeWords(value);
|
|
259
|
+
if (!words)
|
|
260
|
+
return undefined;
|
|
261
|
+
let index = 0;
|
|
262
|
+
while (index < words.length) {
|
|
263
|
+
const argument = words[index];
|
|
264
|
+
if (argument === undefined)
|
|
265
|
+
return undefined;
|
|
266
|
+
if (argument === "--")
|
|
267
|
+
return words[index + 1];
|
|
268
|
+
if (argument === "-i" || argument === "--ignore-environment") {
|
|
269
|
+
index += 1;
|
|
270
|
+
continue;
|
|
271
|
+
}
|
|
272
|
+
if (argument === "-u" || argument === "--unset") {
|
|
273
|
+
const name = words[index + 1];
|
|
274
|
+
if (name === undefined || name === "")
|
|
275
|
+
return undefined;
|
|
276
|
+
index += 2;
|
|
277
|
+
continue;
|
|
278
|
+
}
|
|
279
|
+
if (argument.startsWith("--unset=")) {
|
|
280
|
+
if (argument.length === "--unset=".length)
|
|
281
|
+
return undefined;
|
|
282
|
+
index += 1;
|
|
283
|
+
continue;
|
|
284
|
+
}
|
|
285
|
+
if (/^[A-Za-z_][A-Za-z0-9_]*=/.test(argument)) {
|
|
286
|
+
index += 1;
|
|
287
|
+
continue;
|
|
288
|
+
}
|
|
289
|
+
if (argument.startsWith("-"))
|
|
290
|
+
return undefined;
|
|
291
|
+
return argument;
|
|
292
|
+
}
|
|
293
|
+
return undefined;
|
|
294
|
+
}
|
|
295
|
+
function interpreterFor(command) {
|
|
296
|
+
const name = basename(command).toLowerCase();
|
|
297
|
+
const withoutExe = name.endsWith(".exe") ? name.slice(0, -4) : name;
|
|
298
|
+
if (/^(?:python|python\d+(?:\.\d+)*)$/.test(withoutExe)) {
|
|
299
|
+
return { name: withoutExe, language: "python" };
|
|
300
|
+
}
|
|
301
|
+
if (/^ruby(?:\d+(?:\.\d+)*)?$/.test(withoutExe)) {
|
|
302
|
+
return { name: withoutExe, language: "ruby" };
|
|
303
|
+
}
|
|
304
|
+
if (["node", "nodejs"].includes(withoutExe)) {
|
|
305
|
+
return { name: withoutExe, language: "javascript" };
|
|
306
|
+
}
|
|
307
|
+
if (withoutExe === "bash" || /^bash\d+$/.test(withoutExe)) {
|
|
308
|
+
return { name: withoutExe, language: "bash" };
|
|
309
|
+
}
|
|
310
|
+
if (SHELL_INTERPRETERS.has(withoutExe)) {
|
|
311
|
+
return { name: withoutExe, family: "shell" };
|
|
312
|
+
}
|
|
313
|
+
if (/^(?:perl|perl\d+(?:\.\d+)*)$/.test(withoutExe)) {
|
|
314
|
+
return { name: withoutExe, language: "perl" };
|
|
315
|
+
}
|
|
316
|
+
if (["prolog", "swipl", "gprolog"].includes(withoutExe)) {
|
|
317
|
+
return { name: withoutExe, language: "prolog" };
|
|
318
|
+
}
|
|
319
|
+
return { name: withoutExe || "unknown" };
|
|
320
|
+
}
|
|
321
|
+
function shebangFor(content) {
|
|
322
|
+
const bomOffset = content.charCodeAt(0) === 0xfeff ? 1 : 0;
|
|
323
|
+
const prefix = content.slice(bomOffset, bomOffset + MAX_SHEBANG_LENGTH + 2);
|
|
324
|
+
if (!prefix.startsWith("#!"))
|
|
325
|
+
return undefined;
|
|
326
|
+
const lineEnd = prefix.search(/[\r\n]/);
|
|
327
|
+
if (lineEnd < 0 && content.length > bomOffset + MAX_SHEBANG_LENGTH + 2) {
|
|
328
|
+
return { name: "overlong-shebang" };
|
|
329
|
+
}
|
|
330
|
+
const line = prefix.slice(2, lineEnd < 0 ? undefined : lineEnd).trim();
|
|
331
|
+
const words = tokenizeWords(line);
|
|
332
|
+
if (!words || words.length === 0 || words[0] === undefined) {
|
|
333
|
+
return { name: "malformed-shebang" };
|
|
334
|
+
}
|
|
335
|
+
const executable = basename(words[0]).toLowerCase();
|
|
336
|
+
if (executable === "env") {
|
|
337
|
+
const command = envCommand(words.slice(1));
|
|
338
|
+
return command === undefined
|
|
339
|
+
? { name: "malformed-env-shebang" }
|
|
340
|
+
: interpreterFor(command);
|
|
341
|
+
}
|
|
342
|
+
return interpreterFor(words[0]);
|
|
343
|
+
}
|
|
344
|
+
function classificationForLanguage(language, source) {
|
|
345
|
+
if (FILE_LEVEL_LANGUAGES.has(language)) {
|
|
346
|
+
return {
|
|
347
|
+
kind: "file-level",
|
|
348
|
+
language,
|
|
349
|
+
source,
|
|
350
|
+
reason: `${language} is retained as a file-level classification; no syntax extractor is selected.`,
|
|
351
|
+
};
|
|
352
|
+
}
|
|
353
|
+
return { kind: "language", language, source };
|
|
354
|
+
}
|
|
355
|
+
function isExtensionCompatibleWith(extension, language) {
|
|
356
|
+
if (extension.kind === "ambiguous")
|
|
357
|
+
return extension.candidates.includes(language);
|
|
358
|
+
if (extension.kind === "file-level" && extension.language === "shell") {
|
|
359
|
+
return language === "bash" || language === "shell";
|
|
360
|
+
}
|
|
361
|
+
return extension.language === language;
|
|
362
|
+
}
|
|
363
|
+
function conflict(reason, details = {}) {
|
|
364
|
+
return { kind: "conflict", language: "unknown", reason, ...details };
|
|
365
|
+
}
|
|
366
|
+
/** Classifies a path and bounded snapshot prefix without executing the source or its interpreter. */
|
|
367
|
+
export function classifySource(filePath, content, explicitLanguageHint) {
|
|
368
|
+
const extension = EXTENSIONS[extensionOf(filePath)];
|
|
369
|
+
const explicitRaw = explicitLanguageHint?.trim();
|
|
370
|
+
const explicit = explicitRaw ? canonicalLanguage(explicitRaw) : undefined;
|
|
371
|
+
const shebang = shebangFor(content);
|
|
372
|
+
const shebangLanguage = shebang?.language;
|
|
373
|
+
if (explicitRaw && explicit === undefined) {
|
|
374
|
+
return conflict(`The explicit language hint '${explicitRaw}' is not recognized.`);
|
|
375
|
+
}
|
|
376
|
+
if (explicit !== undefined) {
|
|
377
|
+
if (extension !== undefined &&
|
|
378
|
+
!isExtensionCompatibleWith(extension, explicit)) {
|
|
379
|
+
return conflict(`The explicit language '${explicit}' conflicts with the file extension classification.`, {
|
|
380
|
+
extensionLanguage: extension.language,
|
|
381
|
+
explicitLanguage: explicit,
|
|
382
|
+
...(shebangLanguage === undefined ? {} : { shebangLanguage }),
|
|
383
|
+
});
|
|
384
|
+
}
|
|
385
|
+
if (shebang !== undefined) {
|
|
386
|
+
const shebangMatches = shebang.language === explicit ||
|
|
387
|
+
(shebang.family === "shell" && explicit === "shell");
|
|
388
|
+
if (!shebangMatches) {
|
|
389
|
+
return conflict(`The explicit language '${explicit}' conflicts with the snapshot shebang.`, {
|
|
390
|
+
...(extension === undefined
|
|
391
|
+
? {}
|
|
392
|
+
: { extensionLanguage: extension.language }),
|
|
393
|
+
...(shebangLanguage === undefined ? {} : { shebangLanguage }),
|
|
394
|
+
explicitLanguage: explicit,
|
|
395
|
+
});
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
return classificationForLanguage(explicit, "explicit");
|
|
399
|
+
}
|
|
400
|
+
if (extension?.kind === "ambiguous") {
|
|
401
|
+
if (shebang === undefined) {
|
|
402
|
+
return {
|
|
403
|
+
kind: "ambiguous",
|
|
404
|
+
language: extension.language,
|
|
405
|
+
candidates: extension.candidates,
|
|
406
|
+
reason: `The '${extension.language === "c-or-cpp" ? ".h" : ".pl"}' extension does not select one language.`,
|
|
407
|
+
};
|
|
408
|
+
}
|
|
409
|
+
const resolvedLanguage = shebang.language;
|
|
410
|
+
if (resolvedLanguage !== undefined &&
|
|
411
|
+
extension.candidates.includes(resolvedLanguage)) {
|
|
412
|
+
return classificationForLanguage(resolvedLanguage, "shebang");
|
|
413
|
+
}
|
|
414
|
+
return conflict("The file extension is ambiguous and the shebang does not resolve it to a supported candidate.", {
|
|
415
|
+
extensionLanguage: extension.language,
|
|
416
|
+
...(shebangLanguage === undefined ? {} : { shebangLanguage }),
|
|
417
|
+
});
|
|
418
|
+
}
|
|
419
|
+
const hasExtension = extensionOf(filePath) !== "";
|
|
420
|
+
if (extension !== undefined) {
|
|
421
|
+
if (shebang !== undefined) {
|
|
422
|
+
if (shebang.family === "shell") {
|
|
423
|
+
if (extension.language === "shell") {
|
|
424
|
+
return {
|
|
425
|
+
kind: "file-level",
|
|
426
|
+
language: "shell",
|
|
427
|
+
source: "shebang",
|
|
428
|
+
reason: `The ${shebang.name} shell dialect is retained as file-level source.`,
|
|
429
|
+
};
|
|
430
|
+
}
|
|
431
|
+
return conflict(`The ${shebang.name} shell shebang conflicts with the file extension language.`, {
|
|
432
|
+
extensionLanguage: extension.language,
|
|
433
|
+
shebangLanguage: "shell",
|
|
434
|
+
});
|
|
435
|
+
}
|
|
436
|
+
if (shebang.language !== undefined) {
|
|
437
|
+
if (!isExtensionCompatibleWith(extension, shebang.language)) {
|
|
438
|
+
return conflict(`The ${shebang.language} shebang conflicts with the file extension language.`, {
|
|
439
|
+
extensionLanguage: extension.language,
|
|
440
|
+
shebangLanguage: shebang.language,
|
|
441
|
+
});
|
|
442
|
+
}
|
|
443
|
+
return classificationForLanguage(shebang.language, "shebang");
|
|
444
|
+
}
|
|
445
|
+
return conflict(`The shebang interpreter '${shebang.name}' is not qualified for the file extension language.`, {
|
|
446
|
+
extensionLanguage: extension.language,
|
|
447
|
+
shebangLanguage: shebang.name,
|
|
448
|
+
});
|
|
449
|
+
}
|
|
450
|
+
if (extension.kind === "file-level") {
|
|
451
|
+
return {
|
|
452
|
+
kind: "file-level",
|
|
453
|
+
language: extension.language,
|
|
454
|
+
source: "extension",
|
|
455
|
+
reason: extension.reason,
|
|
456
|
+
};
|
|
457
|
+
}
|
|
458
|
+
return classificationForLanguage(extension.language, "extension");
|
|
459
|
+
}
|
|
460
|
+
if (hasExtension) {
|
|
461
|
+
return {
|
|
462
|
+
kind: "unknown",
|
|
463
|
+
language: "unknown",
|
|
464
|
+
reason: "The file extension is not present in the source language catalog.",
|
|
465
|
+
};
|
|
466
|
+
}
|
|
467
|
+
if (shebang === undefined) {
|
|
468
|
+
return {
|
|
469
|
+
kind: "unknown",
|
|
470
|
+
language: "unknown",
|
|
471
|
+
reason: "No recognized source extension or shebang is present.",
|
|
472
|
+
};
|
|
473
|
+
}
|
|
474
|
+
if (shebang.language !== undefined) {
|
|
475
|
+
return classificationForLanguage(shebang.language, "shebang");
|
|
476
|
+
}
|
|
477
|
+
if (shebang.family === "shell") {
|
|
478
|
+
return {
|
|
479
|
+
kind: "file-level",
|
|
480
|
+
language: "shell",
|
|
481
|
+
source: "shebang",
|
|
482
|
+
reason: `The ${shebang.name} shell dialect is retained as file-level source.`,
|
|
483
|
+
};
|
|
484
|
+
}
|
|
485
|
+
return {
|
|
486
|
+
kind: "unknown",
|
|
487
|
+
language: "unknown",
|
|
488
|
+
reason: `The '${shebang.name}' interpreter is not in the executable source catalog.`,
|
|
489
|
+
};
|
|
490
|
+
}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
export type SwiplSource = "env" | "bundled" | "path";
|
|
2
|
+
export type ResolvedSwipl = {
|
|
3
|
+
/** Absolute path to the executable. */
|
|
4
|
+
bin: string;
|
|
5
|
+
/** SWI_HOME_DIR for a bundled build. */
|
|
6
|
+
home?: string;
|
|
7
|
+
/** Upstream SWI-Prolog version, e.g. "10.0.2". */
|
|
8
|
+
version: string;
|
|
9
|
+
source: SwiplSource;
|
|
10
|
+
};
|
|
11
|
+
export declare const MINIMUM_SWIPL_MAJOR = 9;
|
|
12
|
+
export type SwiplResolutionErrorCode = "swipl_not_found" | "swipl_env_invalid" | "swipl_bundle_corrupt";
|
|
13
|
+
/** Structured failure; `message` is the complete operator-facing guidance. */
|
|
14
|
+
export declare class SwiplResolutionError extends Error {
|
|
15
|
+
readonly code: SwiplResolutionErrorCode;
|
|
16
|
+
/** Detected host, e.g. "linux-x64 (glibc)". */
|
|
17
|
+
readonly platform: string;
|
|
18
|
+
/** Platform package that would have covered this host, when one exists. */
|
|
19
|
+
readonly packageName: string | undefined;
|
|
20
|
+
constructor(code: SwiplResolutionErrorCode, message: string, platform: string, packageName: string | undefined);
|
|
21
|
+
}
|
|
22
|
+
export type SwiplResolverDeps = {
|
|
23
|
+
platform: string;
|
|
24
|
+
arch: string;
|
|
25
|
+
/** True on glibc Linux, false on musl, undefined off Linux. */
|
|
26
|
+
glibc: boolean | undefined;
|
|
27
|
+
/** Directory of an installed platform package, or undefined. */
|
|
28
|
+
locatePackage: (packageName: string) => string | undefined;
|
|
29
|
+
/** Output of `<bin> --version`; throws when the executable cannot run. */
|
|
30
|
+
runVersion: (bin: string) => string;
|
|
31
|
+
};
|
|
32
|
+
/** Parse `SWI-Prolog version 10.0.2 for x86_64-linux` into its version. */
|
|
33
|
+
export declare function parseSwiplVersion(output: string): {
|
|
34
|
+
version: string;
|
|
35
|
+
major: number;
|
|
36
|
+
} | undefined;
|
|
37
|
+
/** Uncached resolution with injectable host facts; the test seam. */
|
|
38
|
+
export declare function resolveSwiplWith(env: NodeJS.ProcessEnv, deps: SwiplResolverDeps): ResolvedSwipl;
|
|
39
|
+
/**
|
|
40
|
+
* Resolve the SWI-Prolog executable for this process. The result is cached for
|
|
41
|
+
* the lifetime of the process, keyed by the inputs that select it.
|
|
42
|
+
*/
|
|
43
|
+
export declare function resolveSwipl(env?: NodeJS.ProcessEnv): ResolvedSwipl;
|
|
44
|
+
/** Test seam: forget every cached resolution. */
|
|
45
|
+
export declare function resetSwiplResolverCache(): void;
|
|
46
|
+
/** Stable identity of a resolved runtime, compared across engine processes. */
|
|
47
|
+
export declare function swiplIdentity(resolved: ResolvedSwipl): string;
|
|
48
|
+
/** Environment additions a child needs to run the resolved SWI-Prolog. */
|
|
49
|
+
export declare function swiplChildEnv(resolved: Pick<ResolvedSwipl, "home">): Record<string, string>;
|
|
50
|
+
export type BundleStatus = {
|
|
51
|
+
state: "unsupported";
|
|
52
|
+
} | {
|
|
53
|
+
state: "missing" | "empty";
|
|
54
|
+
packageName: string;
|
|
55
|
+
} | {
|
|
56
|
+
state: "corrupt";
|
|
57
|
+
packageName: string;
|
|
58
|
+
reason: string;
|
|
59
|
+
} | {
|
|
60
|
+
state: "installed";
|
|
61
|
+
packageName: string;
|
|
62
|
+
};
|
|
63
|
+
/** Report the bundled package's state without resolving a runtime. */
|
|
64
|
+
export declare function inspectSwiplBundle(deps?: SwiplResolverDeps): BundleStatus;
|
|
65
|
+
/** Libraries Kibi loads at runtime; a SWI-Prolog lacking one cannot serve it. */
|
|
66
|
+
export declare const REQUIRED_SWIPL_LIBRARIES: readonly ["semweb/rdf_db", "semweb/rdf_persistency", "semweb/sparql_client", "pcre", "crypto", "sha", "http/json", "http/json_convert", "chr", "clpfd", "thread", "persistency", "filesex", "readutil", "date", "aggregate", "solution_sequences"];
|
|
67
|
+
export type SwiplGoalRunner = (bin: string, args: readonly string[], env: NodeJS.ProcessEnv) => {
|
|
68
|
+
status: number | null;
|
|
69
|
+
stdout: string;
|
|
70
|
+
stderr: string;
|
|
71
|
+
error?: Error;
|
|
72
|
+
};
|
|
73
|
+
export type LibraryProbe = {
|
|
74
|
+
kind: "ok";
|
|
75
|
+
} | {
|
|
76
|
+
kind: "missing";
|
|
77
|
+
libraries: string[];
|
|
78
|
+
} | {
|
|
79
|
+
kind: "failed";
|
|
80
|
+
detail: string;
|
|
81
|
+
};
|
|
82
|
+
/**
|
|
83
|
+
* Load every required library in one throwaway SWI-Prolog process and report
|
|
84
|
+
* the ones that fail. A probe that cannot run is reported as such, never as a
|
|
85
|
+
* pass.
|
|
86
|
+
*/
|
|
87
|
+
export declare function probeRequiredLibraries(resolved: ResolvedSwipl, run?: SwiplGoalRunner, env?: NodeJS.ProcessEnv): LibraryProbe;
|
|
88
|
+
//# sourceMappingURL=swipl-resolver.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"swipl-resolver.d.ts","sourceRoot":"","sources":["../../src/prolog/swipl-resolver.ts"],"names":[],"mappings":"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"}
|