@delta-infra/cli 1.0.97 → 1.0.99
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/README.md +473 -471
- package/checksums.txt +5 -5
- package/package.json +2 -2
- package/scripts/install-wizard.js +701 -701
- package/scripts/install.js +442 -442
- package/scripts/run.js +65 -65
- package/skills/delta-sandbox/SKILL.md +382 -356
- package/skills/delta-sandbox/agents/openai.yaml +4 -4
- package/skills/delta-sandbox/references/commands.md +58 -56
- package/skills/delta-sandbox/references/lifecycle.md +100 -92
- package/skills/delta-sandbox/references/recipes.md +138 -133
- package/skills/delta-science/AGENTS.md +46 -49
- package/skills/delta-science/SKILL.md +130 -131
- package/skills/delta-science/agents/openai.yaml +4 -4
- package/skills/delta-science/references/antbo.md +100 -100
- package/skills/delta-science/references/delta-bo.md +89 -89
- package/skills/delta-science/references/gsasii.md +116 -116
- package/skills/delta-science/references/lammps.md +66 -66
- package/skills/delta-science/references/ldm-bo.md +129 -129
- package/skills/delta-science/references/pubchem.md +126 -126
- package/skills/delta-science/references/pymatgen.md +68 -68
- package/skills/delta-science/references/{qe-dft.md → qe.md} +4 -4
- package/skills/delta-science/references/rdkit.md +138 -138
- package/skills/delta-science/references/strbo.md +87 -87
- package/skills/delta-science/references/synbo.md +198 -198
- package/skills/delta-science/scripts/catalog.py +92 -92
- package/skills/delta-science/scripts/generated_catalog.py +69 -69
- package/skills/delta-science/scripts/invoke.py +302 -302
- package/skills/delta-shared/SKILL.md +97 -95
- package/skills/delta-shared/agents/openai.yaml +4 -4
- package/skills/manifest.json +19 -19
- package/skills/delta-science/references/cli-contract.md +0 -53
- package/skills/delta-science/references/generated-catalog.md +0 -48
- package/skills/delta-science/references/ldm.md +0 -73
- package/skills/delta-science/references/molecule-enrich.md +0 -59
- package/skills/delta-science/references/operation-contracts.md +0 -137
- package/skills/delta-science/references/routing-index.md +0 -45
- package/skills/delta-science/references/services.md +0 -112
- package/skills/delta-science/references/workflows.md +0 -98
package/scripts/run.js
CHANGED
|
@@ -1,65 +1,65 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// Copyright (c) 2026 Delta
|
|
3
|
-
// SPDX-License-Identifier: MIT
|
|
4
|
-
|
|
5
|
-
const { execFileSync } = require("child_process");
|
|
6
|
-
const fs = require("fs");
|
|
7
|
-
const path = require("path");
|
|
8
|
-
|
|
9
|
-
const ext = process.platform === "win32" ? ".exe" : "";
|
|
10
|
-
const bin = path.join(__dirname, "..", "bin", "delta-cli" + ext);
|
|
11
|
-
|
|
12
|
-
// On Windows, a crashed self-update may have left the binary renamed to .old.
|
|
13
|
-
const oldBin = bin + ".old";
|
|
14
|
-
function restoreOldBinary() {
|
|
15
|
-
try {
|
|
16
|
-
if (fs.existsSync(bin)) {
|
|
17
|
-
fs.rmSync(bin, { force: true });
|
|
18
|
-
}
|
|
19
|
-
fs.renameSync(oldBin, bin);
|
|
20
|
-
return true;
|
|
21
|
-
} catch { return false; }
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
if (process.platform === "win32" && fs.existsSync(oldBin)) {
|
|
25
|
-
if (!fs.existsSync(bin)) {
|
|
26
|
-
restoreOldBinary();
|
|
27
|
-
} else {
|
|
28
|
-
try {
|
|
29
|
-
execFileSync(bin, ["--version"], { stdio: "ignore", timeout: 10000 });
|
|
30
|
-
try { fs.rmSync(oldBin, { force: true }); } catch {}
|
|
31
|
-
} catch {
|
|
32
|
-
restoreOldBinary();
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
const args = process.argv.slice(2);
|
|
38
|
-
|
|
39
|
-
// Intercept install/uninstall — run wizard, bypass native binary
|
|
40
|
-
if (args[0] === "install" || args[0] === "uninstall") {
|
|
41
|
-
require("./install-wizard.js");
|
|
42
|
-
} else {
|
|
43
|
-
// Auto-download binary if missing (e.g. npx skipped postinstall)
|
|
44
|
-
if (!fs.existsSync(bin)) {
|
|
45
|
-
try {
|
|
46
|
-
execFileSync(process.execPath, [path.join(__dirname, "install.js")], {
|
|
47
|
-
stdio: "inherit",
|
|
48
|
-
env: { ...process.env, DELTA_CLI_RUN: "true", DELTA_CLI_VERSION: process.env.DELTA_CLI_VERSION || "" },
|
|
49
|
-
});
|
|
50
|
-
} catch {
|
|
51
|
-
console.error(
|
|
52
|
-
`\nFailed to auto-install delta-cli binary.\n` +
|
|
53
|
-
`To fix, run the install script manually:\n` +
|
|
54
|
-
` node "${path.join(__dirname, "install.js")}"\n`
|
|
55
|
-
);
|
|
56
|
-
process.exit(1);
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
try {
|
|
61
|
-
execFileSync(bin, args, { stdio: "inherit" });
|
|
62
|
-
} catch (e) {
|
|
63
|
-
process.exit(e.status || 1);
|
|
64
|
-
}
|
|
65
|
-
}
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// Copyright (c) 2026 Delta Agent Cloud Authors
|
|
3
|
+
// SPDX-License-Identifier: MIT
|
|
4
|
+
|
|
5
|
+
const { execFileSync } = require("child_process");
|
|
6
|
+
const fs = require("fs");
|
|
7
|
+
const path = require("path");
|
|
8
|
+
|
|
9
|
+
const ext = process.platform === "win32" ? ".exe" : "";
|
|
10
|
+
const bin = path.join(__dirname, "..", "bin", "delta-cli" + ext);
|
|
11
|
+
|
|
12
|
+
// On Windows, a crashed self-update may have left the binary renamed to .old.
|
|
13
|
+
const oldBin = bin + ".old";
|
|
14
|
+
function restoreOldBinary() {
|
|
15
|
+
try {
|
|
16
|
+
if (fs.existsSync(bin)) {
|
|
17
|
+
fs.rmSync(bin, { force: true });
|
|
18
|
+
}
|
|
19
|
+
fs.renameSync(oldBin, bin);
|
|
20
|
+
return true;
|
|
21
|
+
} catch { return false; }
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
if (process.platform === "win32" && fs.existsSync(oldBin)) {
|
|
25
|
+
if (!fs.existsSync(bin)) {
|
|
26
|
+
restoreOldBinary();
|
|
27
|
+
} else {
|
|
28
|
+
try {
|
|
29
|
+
execFileSync(bin, ["--version"], { stdio: "ignore", timeout: 10000 });
|
|
30
|
+
try { fs.rmSync(oldBin, { force: true }); } catch {}
|
|
31
|
+
} catch {
|
|
32
|
+
restoreOldBinary();
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
const args = process.argv.slice(2);
|
|
38
|
+
|
|
39
|
+
// Intercept install/uninstall — run wizard, bypass native binary
|
|
40
|
+
if (args[0] === "install" || args[0] === "uninstall") {
|
|
41
|
+
require("./install-wizard.js");
|
|
42
|
+
} else {
|
|
43
|
+
// Auto-download binary if missing (e.g. npx skipped postinstall)
|
|
44
|
+
if (!fs.existsSync(bin)) {
|
|
45
|
+
try {
|
|
46
|
+
execFileSync(process.execPath, [path.join(__dirname, "install.js")], {
|
|
47
|
+
stdio: "inherit",
|
|
48
|
+
env: { ...process.env, DELTA_CLI_RUN: "true", DELTA_CLI_VERSION: process.env.DELTA_CLI_VERSION || "" },
|
|
49
|
+
});
|
|
50
|
+
} catch {
|
|
51
|
+
console.error(
|
|
52
|
+
`\nFailed to auto-install delta-cli binary.\n` +
|
|
53
|
+
`To fix, run the install script manually:\n` +
|
|
54
|
+
` node "${path.join(__dirname, "install.js")}"\n`
|
|
55
|
+
);
|
|
56
|
+
process.exit(1);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
try {
|
|
61
|
+
execFileSync(bin, args, { stdio: "inherit" });
|
|
62
|
+
} catch (e) {
|
|
63
|
+
process.exit(e.status || 1);
|
|
64
|
+
}
|
|
65
|
+
}
|