@leg3ndy/otto-bridge 0.9.1 → 1.0.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 +67 -8
- package/dist/agentic_runtime/patch/structured_patch.js +240 -0
- package/dist/agentic_runtime/workspace/manager.js +1044 -0
- package/dist/cli_terminal.js +490 -0
- package/dist/executors/native_macos.js +3341 -381
- package/dist/local_automations.js +18 -1
- package/dist/main.js +23 -0
- package/dist/runtime.js +91 -13
- package/dist/runtime_cli_client.js +18 -0
- package/dist/runtime_contract.js +516 -0
- package/dist/tool_catalog.js +164 -0
- package/dist/types.js +2 -2
- package/package.json +7 -2
- package/scripts/postinstall.mjs +35 -0
package/dist/types.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export const BRIDGE_CONFIG_VERSION = 1;
|
|
2
|
-
export const BRIDGE_VERSION = "0.
|
|
2
|
+
export const BRIDGE_VERSION = "1.0.0";
|
|
3
3
|
export const BRIDGE_PACKAGE_NAME = "@leg3ndy/otto-bridge";
|
|
4
4
|
export const DEFAULT_API_BASE_URL = "http://localhost:8000";
|
|
5
5
|
export const DEFAULT_POLL_INTERVAL_MS = 3000;
|
|
@@ -10,4 +10,4 @@ export const DEFAULT_RECONNECT_MAX_DELAY_MS = 15000;
|
|
|
10
10
|
export const DEFAULT_EXECUTOR_TYPE = "mock";
|
|
11
11
|
export const DEFAULT_CLAWD_CURSOR_BASE_URL = "http://127.0.0.1:3847";
|
|
12
12
|
export const DEFAULT_CLAWD_CURSOR_POLL_INTERVAL_MS = 1500;
|
|
13
|
-
export const BRIDGE_LOCAL_TOOLS_VERSION =
|
|
13
|
+
export const BRIDGE_LOCAL_TOOLS_VERSION = 7;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@leg3ndy/otto-bridge",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "Local companion for Otto Bridge device pairing and WebSocket runtime.",
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
"license": "MIT",
|
|
24
24
|
"files": [
|
|
25
25
|
"dist",
|
|
26
|
+
"scripts/postinstall.mjs",
|
|
26
27
|
"README.md",
|
|
27
28
|
"package.json"
|
|
28
29
|
],
|
|
@@ -31,16 +32,20 @@
|
|
|
31
32
|
},
|
|
32
33
|
"scripts": {
|
|
33
34
|
"build": "node ./scripts/run-tsc.mjs -p tsconfig.json",
|
|
35
|
+
"test:runtime": "node --test tests/*.test.mjs",
|
|
34
36
|
"typecheck": "node ./scripts/run-tsc.mjs -p tsconfig.json --noEmit",
|
|
35
37
|
"pack:dry-run": "npm pack --dry-run",
|
|
36
38
|
"release:check": "npm run typecheck && npm run build && npm run pack:dry-run",
|
|
37
39
|
"prepublishOnly": "npm run release:check",
|
|
38
40
|
"pair": "node dist/main.js pair",
|
|
41
|
+
"setup": "node dist/main.js setup",
|
|
42
|
+
"console": "node dist/main.js console",
|
|
39
43
|
"run": "node dist/main.js run",
|
|
40
44
|
"status": "node dist/main.js status",
|
|
41
45
|
"version:cli": "node dist/main.js version",
|
|
42
46
|
"update:cli": "node dist/main.js update --dry-run",
|
|
43
|
-
"unpair": "node dist/main.js unpair"
|
|
47
|
+
"unpair": "node dist/main.js unpair",
|
|
48
|
+
"postinstall": "node ./scripts/postinstall.mjs"
|
|
44
49
|
},
|
|
45
50
|
"publishConfig": {
|
|
46
51
|
"access": "public"
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { existsSync } from "node:fs";
|
|
3
|
+
import { homedir } from "node:os";
|
|
4
|
+
import path from "node:path";
|
|
5
|
+
import { spawnSync } from "node:child_process";
|
|
6
|
+
|
|
7
|
+
const isInteractive = Boolean(process.stdout.isTTY && process.stdin.isTTY);
|
|
8
|
+
const isCi = String(process.env.CI || "").toLowerCase() === "true";
|
|
9
|
+
const skipSetup = String(process.env.OTTO_BRIDGE_SKIP_SETUP || "").trim() === "1";
|
|
10
|
+
const forceSetup = String(process.env.OTTO_BRIDGE_FORCE_SETUP || "").trim() === "1";
|
|
11
|
+
const isGlobalInstall = String(process.env.npm_config_global || "").trim() === "true";
|
|
12
|
+
|
|
13
|
+
if (!isInteractive || isCi || skipSetup || (!isGlobalInstall && !forceSetup)) {
|
|
14
|
+
process.exit(0);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
const configPath = path.join(homedir(), ".otto-bridge", "config.json");
|
|
18
|
+
if (existsSync(configPath)) {
|
|
19
|
+
process.exit(0);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const mainPath = path.join(process.cwd(), "dist", "main.js");
|
|
23
|
+
if (!existsSync(mainPath)) {
|
|
24
|
+
process.exit(0);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
console.log("\n[otto-bridge] Welcome to OTTOAI 1.0.0");
|
|
28
|
+
console.log("[otto-bridge] Vamos iniciar o setup interativo do bridge.\n");
|
|
29
|
+
|
|
30
|
+
const result = spawnSync(process.execPath, [mainPath, "setup", "--postinstall"], {
|
|
31
|
+
stdio: "inherit",
|
|
32
|
+
env: process.env,
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
process.exit(typeof result.status === "number" ? result.status : 0);
|