@kesarcloud/omega-plus-cli 2.0.6 → 2.0.8
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/package.json +1 -1
- package/src/constants.mjs +1 -1
- package/src/wizard.mjs +5 -4
package/package.json
CHANGED
package/src/constants.mjs
CHANGED
package/src/wizard.mjs
CHANGED
|
@@ -139,8 +139,8 @@ async function extractApiKeyFromConfig(toolId) {
|
|
|
139
139
|
}
|
|
140
140
|
}
|
|
141
141
|
|
|
142
|
-
export async function runUpdateFlow(options = {}) {
|
|
143
|
-
const rl = createPromptInterface();
|
|
142
|
+
export async function runUpdateFlow(options = {}, externalRl = null) {
|
|
143
|
+
const rl = externalRl || createPromptInterface();
|
|
144
144
|
try {
|
|
145
145
|
const allTools = await detectAllTools();
|
|
146
146
|
const configured = allTools.filter((t) => t.configStatus === "configured" && t.installed);
|
|
@@ -200,7 +200,8 @@ export async function runUpdateFlow(options = {}) {
|
|
|
200
200
|
console.log("\nYour models have been updated to the latest Omega Plus endpoints.");
|
|
201
201
|
return result;
|
|
202
202
|
} finally {
|
|
203
|
-
|
|
203
|
+
// Only close if we created our own readline (not shared with caller)
|
|
204
|
+
if (!externalRl) rl.close();
|
|
204
205
|
}
|
|
205
206
|
}
|
|
206
207
|
|
|
@@ -242,7 +243,7 @@ export async function runWizard(options = {}) {
|
|
|
242
243
|
|
|
243
244
|
// Option 2: Update
|
|
244
245
|
if (menuChoice === 2) {
|
|
245
|
-
return runUpdateFlow(options);
|
|
246
|
+
return await runUpdateFlow(options, rl);
|
|
246
247
|
}
|
|
247
248
|
|
|
248
249
|
// Option 1 or invalid: New Setup (default)
|