hedgequantx 2.6.112 → 2.6.114
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/menus/ai-agent.js +22 -1
package/package.json
CHANGED
package/src/menus/ai-agent.js
CHANGED
|
@@ -1042,7 +1042,28 @@ const setupProxyOAuth = async (provider, config) => {
|
|
|
1042
1042
|
console.log(chalk.gray(' (The page showing http://localhost:54545/callback?code=...)'));
|
|
1043
1043
|
console.log();
|
|
1044
1044
|
|
|
1045
|
-
|
|
1045
|
+
// Use inquirer directly for reliable input on VPS
|
|
1046
|
+
const inquirer = require('inquirer');
|
|
1047
|
+
let callbackUrl = '';
|
|
1048
|
+
try {
|
|
1049
|
+
const result = await inquirer.prompt([{
|
|
1050
|
+
type: 'input',
|
|
1051
|
+
name: 'callbackUrl',
|
|
1052
|
+
message: 'Callback URL:',
|
|
1053
|
+
prefix: ' '
|
|
1054
|
+
}]);
|
|
1055
|
+
callbackUrl = result.callbackUrl || '';
|
|
1056
|
+
} catch (e) {
|
|
1057
|
+
// Inquirer failed, try readline directly
|
|
1058
|
+
const readline = require('readline');
|
|
1059
|
+
const rl = readline.createInterface({ input: process.stdin, output: process.stdout });
|
|
1060
|
+
callbackUrl = await new Promise(resolve => {
|
|
1061
|
+
rl.question(' Callback URL: ', answer => {
|
|
1062
|
+
rl.close();
|
|
1063
|
+
resolve(answer || '');
|
|
1064
|
+
});
|
|
1065
|
+
});
|
|
1066
|
+
}
|
|
1046
1067
|
|
|
1047
1068
|
if (callbackUrl && callbackUrl.trim()) {
|
|
1048
1069
|
const submitSpinner = ora({ text: 'Submitting callback...', color: 'cyan' }).start();
|