@bike4mind/cli 0.2.36-perf-6916-parallel-cli-init.20074 → 0.2.36-perf-6916-parallel-cli-init.20075
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/{chunk-GH6BFNIP.js → chunk-O33MWOVJ.js} +6 -0
- package/dist/{chunk-HDOEES53.js → chunk-XOKF6LMI.js} +6 -6
- package/dist/commands/doctorCommand.js +1 -1
- package/dist/commands/headlessCommand.js +1 -1
- package/dist/commands/updateCommand.js +1 -1
- package/dist/index.js +17 -10
- package/package.json +6 -6
|
@@ -15444,6 +15444,10 @@ var McpManager = class {
|
|
|
15444
15444
|
this.connectionReady = /* @__PURE__ */ new Map();
|
|
15445
15445
|
this.config = config;
|
|
15446
15446
|
}
|
|
15447
|
+
/** Subscribe to background connection state changes for live UI updates. */
|
|
15448
|
+
setOnStateChange(callback) {
|
|
15449
|
+
this.onStateChange = callback;
|
|
15450
|
+
}
|
|
15447
15451
|
/**
|
|
15448
15452
|
* Initialize MCP servers with schema caching.
|
|
15449
15453
|
*
|
|
@@ -15517,6 +15521,7 @@ var McpManager = class {
|
|
|
15517
15521
|
}
|
|
15518
15522
|
this.connectionStates.set(serverConfig.name, "connected");
|
|
15519
15523
|
this.connectionReady.get(serverConfig.name)?.resolve();
|
|
15524
|
+
this.onStateChange?.();
|
|
15520
15525
|
logger.debug(`\u2705 Background connection to ${serverConfig.name} established`);
|
|
15521
15526
|
this.writeCacheEntry(cache, serverConfig, client.tools);
|
|
15522
15527
|
this.saveCache(cache).catch(() => {
|
|
@@ -15524,6 +15529,7 @@ var McpManager = class {
|
|
|
15524
15529
|
}).catch((err) => {
|
|
15525
15530
|
this.connectionStates.set(serverConfig.name, "failed");
|
|
15526
15531
|
this.connectionReady.get(serverConfig.name)?.reject(err);
|
|
15532
|
+
this.onStateChange?.();
|
|
15527
15533
|
logger.debug(`\u274C Background connection to ${serverConfig.name} failed: ${err}`);
|
|
15528
15534
|
});
|
|
15529
15535
|
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// package.json
|
|
4
4
|
var package_default = {
|
|
5
5
|
name: "@bike4mind/cli",
|
|
6
|
-
version: "0.2.36-perf-6916-parallel-cli-init.
|
|
6
|
+
version: "0.2.36-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
7
7
|
type: "module",
|
|
8
8
|
description: "Interactive CLI tool for Bike4Mind with ReAct agents",
|
|
9
9
|
license: "UNLICENSED",
|
|
@@ -114,10 +114,10 @@ var package_default = {
|
|
|
114
114
|
},
|
|
115
115
|
devDependencies: {
|
|
116
116
|
"@bike4mind/agents": "0.1.0",
|
|
117
|
-
"@bike4mind/common": "2.57.1-perf-6916-parallel-cli-init.
|
|
118
|
-
"@bike4mind/mcp": "1.32.5-perf-6916-parallel-cli-init.
|
|
119
|
-
"@bike4mind/services": "2.54.1-perf-6916-parallel-cli-init.
|
|
120
|
-
"@bike4mind/utils": "2.10.1-perf-6916-parallel-cli-init.
|
|
117
|
+
"@bike4mind/common": "2.57.1-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
118
|
+
"@bike4mind/mcp": "1.32.5-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
119
|
+
"@bike4mind/services": "2.54.1-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
120
|
+
"@bike4mind/utils": "2.10.1-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
121
121
|
"@types/better-sqlite3": "^7.6.13",
|
|
122
122
|
"@types/diff": "^5.0.9",
|
|
123
123
|
"@types/jsonwebtoken": "^9.0.4",
|
|
@@ -138,7 +138,7 @@ var package_default = {
|
|
|
138
138
|
optionalDependencies: {
|
|
139
139
|
"@vscode/ripgrep": "^1.17.0"
|
|
140
140
|
},
|
|
141
|
-
gitHead: "
|
|
141
|
+
gitHead: "a6ccd6e721ffb49ffb8d1c5184cb36b90104d736"
|
|
142
142
|
};
|
|
143
143
|
|
|
144
144
|
// src/utils/updateChecker.ts
|
package/dist/index.js
CHANGED
|
@@ -46,7 +46,7 @@ import {
|
|
|
46
46
|
setWebSocketToolExecutor,
|
|
47
47
|
substituteArguments,
|
|
48
48
|
warmFileCache
|
|
49
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-O33MWOVJ.js";
|
|
50
50
|
import "./chunk-BDQBOLYG.js";
|
|
51
51
|
import "./chunk-CWQT33O7.js";
|
|
52
52
|
import "./chunk-GQGOWACU.js";
|
|
@@ -62,7 +62,7 @@ import {
|
|
|
62
62
|
import {
|
|
63
63
|
checkForUpdate,
|
|
64
64
|
package_default
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-XOKF6LMI.js";
|
|
66
66
|
import {
|
|
67
67
|
selectActiveBackgroundAgents,
|
|
68
68
|
useCliStore
|
|
@@ -74,7 +74,7 @@ import {
|
|
|
74
74
|
import "./chunk-4BIBE3J7.js";
|
|
75
75
|
|
|
76
76
|
// src/index.tsx
|
|
77
|
-
import React22, { useState as useState11, useEffect as
|
|
77
|
+
import React22, { useState as useState11, useEffect as useEffect8, useCallback as useCallback3, useRef as useRef3 } from "react";
|
|
78
78
|
import { render, Box as Box21, Text as Text21, useApp, useInput as useInput10 } from "ink";
|
|
79
79
|
import { execSync } from "child_process";
|
|
80
80
|
import { randomBytes } from "crypto";
|
|
@@ -84,7 +84,7 @@ import path2 from "path";
|
|
|
84
84
|
import { v4 as uuidv42 } from "uuid";
|
|
85
85
|
|
|
86
86
|
// src/components/App.tsx
|
|
87
|
-
import React16, { useState as useState7, useEffect as
|
|
87
|
+
import React16, { useState as useState7, useEffect as useEffect6 } from "react";
|
|
88
88
|
import { Box as Box15, Text as Text15, Static, useInput as useInput7 } from "ink";
|
|
89
89
|
|
|
90
90
|
// src/components/StatusBar.tsx
|
|
@@ -1471,9 +1471,16 @@ function ConfigEditor({ config, availableModels, onSave, onClose }) {
|
|
|
1471
1471
|
}
|
|
1472
1472
|
|
|
1473
1473
|
// src/components/McpViewer.tsx
|
|
1474
|
-
import React13 from "react";
|
|
1474
|
+
import React13, { useEffect as useEffect5, useReducer } from "react";
|
|
1475
1475
|
import { Box as Box12, Text as Text12, useInput as useInput6 } from "ink";
|
|
1476
1476
|
function McpViewer({ config, mcpManager, onClose }) {
|
|
1477
|
+
const [, forceUpdate] = useReducer((x) => x + 1, 0);
|
|
1478
|
+
useEffect5(() => {
|
|
1479
|
+
if (!mcpManager) return;
|
|
1480
|
+
mcpManager.setOnStateChange(forceUpdate);
|
|
1481
|
+
return () => mcpManager.setOnStateChange(() => {
|
|
1482
|
+
});
|
|
1483
|
+
}, [mcpManager]);
|
|
1477
1484
|
useInput6((input, key) => {
|
|
1478
1485
|
if (key.escape || input === "q") {
|
|
1479
1486
|
onClose();
|
|
@@ -1695,7 +1702,7 @@ function App({
|
|
|
1695
1702
|
const setIsThinking = useCliStore((state) => state.setIsThinking);
|
|
1696
1703
|
const pendingBackgroundTrigger = useCliStore((state) => state.pendingBackgroundTrigger);
|
|
1697
1704
|
const setPendingBackgroundTrigger = useCliStore((state) => state.setPendingBackgroundTrigger);
|
|
1698
|
-
|
|
1705
|
+
useEffect6(() => {
|
|
1699
1706
|
if (pendingBackgroundTrigger && !isThinking && onBackgroundCompletion) {
|
|
1700
1707
|
setPendingBackgroundTrigger(false);
|
|
1701
1708
|
onBackgroundCompletion();
|
|
@@ -2003,7 +2010,7 @@ function SessionSelector({ sessions, currentSession, onSelect, onCancel }) {
|
|
|
2003
2010
|
}
|
|
2004
2011
|
|
|
2005
2012
|
// src/components/LoginFlow.tsx
|
|
2006
|
-
import React21, { useState as useState10, useEffect as
|
|
2013
|
+
import React21, { useState as useState10, useEffect as useEffect7 } from "react";
|
|
2007
2014
|
import { Box as Box20, Text as Text20 } from "ink";
|
|
2008
2015
|
import Spinner3 from "ink-spinner";
|
|
2009
2016
|
import jwt from "jsonwebtoken";
|
|
@@ -2041,7 +2048,7 @@ function LoginFlow({ apiUrl = "http://localhost:3000", configStore, onSuccess, o
|
|
|
2041
2048
|
const [deviceFlow, setDeviceFlow] = useState10(null);
|
|
2042
2049
|
const [statusMessage, setStatusMessage] = useState10("Initiating device authorization...");
|
|
2043
2050
|
const [error, setError] = useState10(null);
|
|
2044
|
-
|
|
2051
|
+
useEffect7(() => {
|
|
2045
2052
|
const runLoginFlow = async () => {
|
|
2046
2053
|
const oauth = new OAuthClient(apiUrl);
|
|
2047
2054
|
try {
|
|
@@ -2076,7 +2083,7 @@ function LoginFlow({ apiUrl = "http://localhost:3000", configStore, onSuccess, o
|
|
|
2076
2083
|
};
|
|
2077
2084
|
runLoginFlow();
|
|
2078
2085
|
}, [apiUrl, configStore, onSuccess, onError]);
|
|
2079
|
-
|
|
2086
|
+
useEffect7(() => {
|
|
2080
2087
|
if (deviceFlow && status === "waiting") {
|
|
2081
2088
|
open(deviceFlow.verification_uri_complete).catch((err) => {
|
|
2082
2089
|
console.error("Failed to auto-open browser:", err);
|
|
@@ -3199,7 +3206,7 @@ function CliApp() {
|
|
|
3199
3206
|
setStoreSession,
|
|
3200
3207
|
setState
|
|
3201
3208
|
]);
|
|
3202
|
-
|
|
3209
|
+
useEffect8(() => {
|
|
3203
3210
|
init();
|
|
3204
3211
|
}, [init]);
|
|
3205
3212
|
const handleCustomCommandMessage = async (fullTemplate, displayMessage) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bike4mind/cli",
|
|
3
|
-
"version": "0.2.36-perf-6916-parallel-cli-init.
|
|
3
|
+
"version": "0.2.36-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Interactive CLI tool for Bike4Mind with ReAct agents",
|
|
6
6
|
"license": "UNLICENSED",
|
|
@@ -111,10 +111,10 @@
|
|
|
111
111
|
},
|
|
112
112
|
"devDependencies": {
|
|
113
113
|
"@bike4mind/agents": "0.1.0",
|
|
114
|
-
"@bike4mind/common": "2.57.1-perf-6916-parallel-cli-init.
|
|
115
|
-
"@bike4mind/mcp": "1.32.5-perf-6916-parallel-cli-init.
|
|
116
|
-
"@bike4mind/services": "2.54.1-perf-6916-parallel-cli-init.
|
|
117
|
-
"@bike4mind/utils": "2.10.1-perf-6916-parallel-cli-init.
|
|
114
|
+
"@bike4mind/common": "2.57.1-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
115
|
+
"@bike4mind/mcp": "1.32.5-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
116
|
+
"@bike4mind/services": "2.54.1-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
117
|
+
"@bike4mind/utils": "2.10.1-perf-6916-parallel-cli-init.20075+a6ccd6e72",
|
|
118
118
|
"@types/better-sqlite3": "^7.6.13",
|
|
119
119
|
"@types/diff": "^5.0.9",
|
|
120
120
|
"@types/jsonwebtoken": "^9.0.4",
|
|
@@ -135,5 +135,5 @@
|
|
|
135
135
|
"optionalDependencies": {
|
|
136
136
|
"@vscode/ripgrep": "^1.17.0"
|
|
137
137
|
},
|
|
138
|
-
"gitHead": "
|
|
138
|
+
"gitHead": "a6ccd6e721ffb49ffb8d1c5184cb36b90104d736"
|
|
139
139
|
}
|