@awebai/aw 1.26.7 → 1.26.9

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.
Files changed (2) hide show
  1. package/bin/aweb-a2a-gw +38 -0
  2. package/package.json +9 -8
@@ -0,0 +1,38 @@
1
+ #!/usr/bin/env node
2
+ "use strict";
3
+ const { execFileSync } = require("child_process");
4
+ const os = require("os");
5
+
6
+ const PLATFORMS = {
7
+ "linux x64": { pkg: "@awebai/aw-linux-x64", bin: "bin/aweb-a2a-gw" },
8
+ "linux arm64": { pkg: "@awebai/aw-linux-arm64", bin: "bin/aweb-a2a-gw" },
9
+ "darwin x64": { pkg: "@awebai/aw-darwin-x64", bin: "bin/aweb-a2a-gw" },
10
+ "darwin arm64": { pkg: "@awebai/aw-darwin-arm64", bin: "bin/aweb-a2a-gw" },
11
+ "win32 x64": { pkg: "@awebai/aw-windows-x64", bin: "bin/aweb-a2a-gw.exe" },
12
+ "win32 arm64": { pkg: "@awebai/aw-windows-arm64", bin: "bin/aweb-a2a-gw.exe" },
13
+ };
14
+
15
+ const key = `${process.platform} ${os.arch()}`;
16
+ const platform = PLATFORMS[key];
17
+ if (!platform) {
18
+ console.error(`Error: Unsupported platform: ${key}`);
19
+ console.error("Visit https://github.com/awebai/aw for installation alternatives.");
20
+ process.exit(1);
21
+ }
22
+
23
+ let binPath;
24
+ try {
25
+ binPath = require.resolve(`${platform.pkg}/${platform.bin}`);
26
+ } catch {
27
+ console.error(`Error: Could not find the aweb-a2a-gw binary for ${key}.`);
28
+ console.error("The platform-specific @awebai/aw package may not have been installed.");
29
+ console.error("Try: npm install @awebai/aw --force");
30
+ process.exit(1);
31
+ }
32
+
33
+ try {
34
+ execFileSync(binPath, process.argv.slice(2), { stdio: "inherit" });
35
+ } catch (e) {
36
+ if (e.status !== null) process.exit(e.status);
37
+ throw e;
38
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@awebai/aw",
3
- "version": "1.26.7",
3
+ "version": "1.26.9",
4
4
  "description": "CLI for the aWeb agent coordination protocol",
5
5
  "repository": {
6
6
  "type": "git",
@@ -8,7 +8,8 @@
8
8
  },
9
9
  "license": "MIT",
10
10
  "bin": {
11
- "aw": "bin/aw"
11
+ "aw": "bin/aw",
12
+ "aweb-a2a-gw": "bin/aweb-a2a-gw"
12
13
  },
13
14
  "scripts": {
14
15
  "postinstall": "node install.js"
@@ -18,11 +19,11 @@
18
19
  },
19
20
  "preferUnplugged": true,
20
21
  "optionalDependencies": {
21
- "@awebai/aw-linux-x64": "1.26.7",
22
- "@awebai/aw-linux-arm64": "1.26.7",
23
- "@awebai/aw-darwin-x64": "1.26.7",
24
- "@awebai/aw-darwin-arm64": "1.26.7",
25
- "@awebai/aw-windows-x64": "1.26.7",
26
- "@awebai/aw-windows-arm64": "1.26.7"
22
+ "@awebai/aw-linux-x64": "1.26.9",
23
+ "@awebai/aw-linux-arm64": "1.26.9",
24
+ "@awebai/aw-darwin-x64": "1.26.9",
25
+ "@awebai/aw-darwin-arm64": "1.26.9",
26
+ "@awebai/aw-windows-x64": "1.26.9",
27
+ "@awebai/aw-windows-arm64": "1.26.9"
27
28
  }
28
29
  }