gaia-framework 1.57.2 → 1.58.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/README.md +1 -1
- package/bin/gaia-framework.js +19 -27
- package/gaia-install.sh +1 -1
- package/package.json +5 -14
package/README.md
CHANGED
package/bin/gaia-framework.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
// ─────────────────────────────────────────────────────────────────────────────
|
|
7
7
|
|
|
8
8
|
const { execSync, execFileSync } = require("child_process");
|
|
9
|
-
const { mkdtempSync, rmSync, existsSync, readFileSync } = require("fs");
|
|
9
|
+
const { mkdtempSync, rmSync, existsSync, readFileSync, realpathSync } = require("fs");
|
|
10
10
|
const { join } = require("path");
|
|
11
11
|
const { tmpdir } = require("os");
|
|
12
12
|
|
|
@@ -35,9 +35,9 @@ function findBash() {
|
|
|
35
35
|
|
|
36
36
|
// 1. Try Git for Windows FIRST (preferred — simpler path mapping)
|
|
37
37
|
const gitBashPaths = [
|
|
38
|
-
join(process.env.ProgramFiles || "C:\\Program Files", "Git", "bin", "bash.exe"),
|
|
39
|
-
join(process.env["ProgramFiles(x86)"] || "C:\\Program Files (x86)", "Git", "bin", "bash.exe"),
|
|
40
|
-
join(process.env.LOCALAPPDATA || "", "Programs", "Git", "bin", "bash.exe"),
|
|
38
|
+
path.join(process.env.ProgramFiles || "C:\\Program Files", "Git", "bin", "bash.exe"),
|
|
39
|
+
path.join(process.env["ProgramFiles(x86)"] || "C:\\Program Files (x86)", "Git", "bin", "bash.exe"),
|
|
40
|
+
path.join(process.env.LOCALAPPDATA || "", "Programs", "Git", "bin", "bash.exe"),
|
|
41
41
|
];
|
|
42
42
|
|
|
43
43
|
for (const p of gitBashPaths) {
|
|
@@ -52,10 +52,7 @@ function findBash() {
|
|
|
52
52
|
execSync("bash --version", { stdio: "ignore" });
|
|
53
53
|
// Detect WSL vs Git Bash by checking uname
|
|
54
54
|
try {
|
|
55
|
-
const uname = execSync('bash -c "uname -r"', {
|
|
56
|
-
encoding: "utf8",
|
|
57
|
-
stdio: ["pipe", "pipe", "ignore"],
|
|
58
|
-
}).trim();
|
|
55
|
+
const uname = execSync('bash -c "uname -r"', { encoding: "utf8", stdio: ["pipe", "pipe", "ignore"] }).trim();
|
|
59
56
|
if (/microsoft|wsl/i.test(uname)) {
|
|
60
57
|
bashType = "wsl";
|
|
61
58
|
} else {
|
|
@@ -64,10 +61,7 @@ function findBash() {
|
|
|
64
61
|
} catch {
|
|
65
62
|
// Can't detect — try MSYSTEM env which Git Bash sets
|
|
66
63
|
try {
|
|
67
|
-
const msys = execSync('bash -c "echo $MSYSTEM"', {
|
|
68
|
-
encoding: "utf8",
|
|
69
|
-
stdio: ["pipe", "pipe", "ignore"],
|
|
70
|
-
}).trim();
|
|
64
|
+
const msys = execSync('bash -c "echo $MSYSTEM"', { encoding: "utf8", stdio: ["pipe", "pipe", "ignore"] }).trim();
|
|
71
65
|
bashType = msys ? "gitbash" : "wsl";
|
|
72
66
|
} catch {
|
|
73
67
|
bashType = "wsl"; // Assume WSL if detection fails — safer path mapping
|
|
@@ -102,7 +96,10 @@ function ensureGit() {
|
|
|
102
96
|
try {
|
|
103
97
|
execSync("git --version", { stdio: "ignore" });
|
|
104
98
|
} catch {
|
|
105
|
-
fail(
|
|
99
|
+
fail(
|
|
100
|
+
"git is required but was not found.\n" +
|
|
101
|
+
" Install git: https://git-scm.com/downloads"
|
|
102
|
+
);
|
|
106
103
|
}
|
|
107
104
|
}
|
|
108
105
|
|
|
@@ -147,9 +144,12 @@ Examples:
|
|
|
147
144
|
|
|
148
145
|
function main(deps) {
|
|
149
146
|
// Dependency injection for testability — defaults to real modules
|
|
150
|
-
const _exec =
|
|
151
|
-
const
|
|
152
|
-
const
|
|
147
|
+
const _exec = deps && deps.execSync || execSync;
|
|
148
|
+
const _execFile = deps && deps.execFileSync || execFileSync;
|
|
149
|
+
const _mkdtemp = deps && deps.mkdtempSync || mkdtempSync;
|
|
150
|
+
const _exists = deps && deps.existsSync || existsSync;
|
|
151
|
+
const _join = deps && deps.join || join;
|
|
152
|
+
const _tmpdir = deps && deps.tmpdir || tmpdir;
|
|
153
153
|
|
|
154
154
|
const args = process.argv.slice(2);
|
|
155
155
|
|
|
@@ -191,14 +191,8 @@ function main(deps) {
|
|
|
191
191
|
|
|
192
192
|
// Register cleanup for all exit scenarios
|
|
193
193
|
process.on("exit", cleanup);
|
|
194
|
-
process.on("SIGINT", () => {
|
|
195
|
-
|
|
196
|
-
process.exit(130);
|
|
197
|
-
});
|
|
198
|
-
process.on("SIGTERM", () => {
|
|
199
|
-
cleanup();
|
|
200
|
-
process.exit(143);
|
|
201
|
-
});
|
|
194
|
+
process.on("SIGINT", () => { cleanup(); process.exit(130); });
|
|
195
|
+
process.on("SIGTERM", () => { cleanup(); process.exit(143); });
|
|
202
196
|
|
|
203
197
|
info("Cloning GAIA framework from GitHub...");
|
|
204
198
|
|
|
@@ -239,9 +233,7 @@ function main(deps) {
|
|
|
239
233
|
|
|
240
234
|
try {
|
|
241
235
|
// Convert all passthrough args that look like paths (contain backslash or drive letter)
|
|
242
|
-
const posixArgs = passthrough.map((a)
|
|
243
|
-
IS_WINDOWS && /[\\:]/.test(a) && !a.startsWith("--") ? toPosixPath(a) : a
|
|
244
|
-
);
|
|
236
|
+
const posixArgs = passthrough.map(a => IS_WINDOWS && /[\\:]/.test(a) && !a.startsWith("--") ? toPosixPath(a) : a);
|
|
245
237
|
const posixScript = toPosixPath(scriptPath);
|
|
246
238
|
|
|
247
239
|
// Debug: on Windows, log the resolved paths if --verbose is passed
|
package/gaia-install.sh
CHANGED
|
@@ -6,7 +6,7 @@ set -euo pipefail
|
|
|
6
6
|
# Installs, updates, validates, and reports on GAIA installations.
|
|
7
7
|
# ─────────────────────────────────────────────────────────────────────────────
|
|
8
8
|
|
|
9
|
-
readonly VERSION="1.
|
|
9
|
+
readonly VERSION="1.58.0"
|
|
10
10
|
readonly GITHUB_REPO="https://github.com/jlouage/Gaia-framework.git"
|
|
11
11
|
readonly MANIFEST_REL="_gaia/_config/manifest.yaml"
|
|
12
12
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gaia-framework",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.58.0",
|
|
4
4
|
"description": "GAIA — Generative Agile Intelligence Architecture installer",
|
|
5
5
|
"bin": {
|
|
6
6
|
"gaia-framework": "./bin/gaia-framework.js"
|
|
@@ -15,11 +15,7 @@
|
|
|
15
15
|
"test:shell": "node -e \"if(process.platform==='win32'){console.log('BATS tests skipped on Windows');process.exit(0)}\" && bats test/shell/",
|
|
16
16
|
"test:all": "vitest run && node -e \"if(process.platform==='win32'){console.log('BATS tests skipped on Windows');process.exit(0)}\" && bats test/shell/",
|
|
17
17
|
"test:tier2": "vitest run --config vitest.config.tier2.js",
|
|
18
|
-
"fixtures:check": "node test/fixtures/sync-check.js"
|
|
19
|
-
"lint": "eslint bin/**/*.js test/**/*.js",
|
|
20
|
-
"lint:fix": "eslint --fix bin/**/*.js test/**/*.js",
|
|
21
|
-
"format:check": "prettier --check \"bin/**/*.js\" \"test/**/*.js\"",
|
|
22
|
-
"format": "prettier --write \"bin/**/*.js\" \"test/**/*.js\""
|
|
18
|
+
"fixtures:check": "node test/fixtures/sync-check.js"
|
|
23
19
|
},
|
|
24
20
|
"keywords": [
|
|
25
21
|
"gaia",
|
|
@@ -43,15 +39,10 @@
|
|
|
43
39
|
"gaia-install.sh"
|
|
44
40
|
],
|
|
45
41
|
"devDependencies": {
|
|
46
|
-
"
|
|
42
|
+
"vitest": "^3.1.0",
|
|
47
43
|
"@vitest/coverage-v8": "^3.1.0",
|
|
48
|
-
"csv-parse": "^5.6.0",
|
|
49
|
-
"eslint": "^9.39.4",
|
|
50
|
-
"eslint-config-prettier": "^10.1.8",
|
|
51
|
-
"fast-xml-parser": "^5.2.0",
|
|
52
|
-
"globals": "^17.4.0",
|
|
53
44
|
"js-yaml": "^4.1.0",
|
|
54
|
-
"
|
|
55
|
-
"
|
|
45
|
+
"fast-xml-parser": "^5.2.0",
|
|
46
|
+
"csv-parse": "^5.6.0"
|
|
56
47
|
}
|
|
57
48
|
}
|