oh-aicoding-tool 0.1.1 → 0.1.2
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/bin/cli.js +6 -5
- package/opencode-ohai-report/bin/cli.js +1 -1
- package/opencode-ohai-report/scripts/install-claude-plugin.ps1 +1 -1
- package/opencode-ohai-report/scripts/install-opencode-plugin.ps1 +1 -1
- package/opencode-ohai-report/scripts/install-opencode-plugin.sh +1 -1
- package/package.json +1 -1
package/bin/cli.js
CHANGED
|
@@ -167,7 +167,7 @@ function renderMultiChoiceScreen(title, choices, index, selected, subtitle) {
|
|
|
167
167
|
choices.forEach((choice, idx) => {
|
|
168
168
|
const focused = idx === index;
|
|
169
169
|
const checked = selected.has(choice.value);
|
|
170
|
-
const box = checked ? paint("[
|
|
170
|
+
const box = checked ? paint("[✓]", t.teal, t.bold) : paint("[ ]", t.muted);
|
|
171
171
|
const cursor = focused ? paint(">", t.teal, t.bold) : " ";
|
|
172
172
|
const label = focused
|
|
173
173
|
? paint(` ${choice.label} `, t.bold, t.selectedFg, t.selectedBg)
|
|
@@ -252,14 +252,15 @@ async function askEmail(rl) {
|
|
|
252
252
|
console.log("");
|
|
253
253
|
console.log(paint("Company email", t.bold, t.blue));
|
|
254
254
|
console.log(paint("Used as the stable user identity in issue reports.", t.muted));
|
|
255
|
-
console.log(paint("
|
|
255
|
+
console.log(paint("Examples: xxxxx@huawei.com or xxxxx@h-partners.com", t.muted));
|
|
256
|
+
console.log(paint("Press Enter to skip Company email setup for now.", t.muted));
|
|
256
257
|
console.log("");
|
|
257
258
|
while (true) {
|
|
258
|
-
const answer = (await rl.question(`${paint("
|
|
259
|
+
const answer = (await rl.question(`${paint("Company email", t.cyan)}${paint(hint, t.muted)} > `)).trim();
|
|
259
260
|
const value = answer || (emailIsValid(envEmail) ? envEmail.trim() : "");
|
|
260
261
|
if (!value) return "";
|
|
261
262
|
if (emailIsValid(value)) return value;
|
|
262
|
-
console.log(paint("Invalid email.
|
|
263
|
+
console.log(paint("Invalid Company email. Examples: xxxxx@huawei.com or xxxxx@h-partners.com", t.red));
|
|
263
264
|
}
|
|
264
265
|
}
|
|
265
266
|
|
|
@@ -278,7 +279,7 @@ async function collectInstallPlan(rl) {
|
|
|
278
279
|
label: "Issue report plugin",
|
|
279
280
|
value: "report",
|
|
280
281
|
selected: true,
|
|
281
|
-
description: "Install /report-ai-issue and configure
|
|
282
|
+
description: "Install /report-ai-issue and configure Company email.",
|
|
282
283
|
},
|
|
283
284
|
],
|
|
284
285
|
"Install menu"
|
|
@@ -141,7 +141,7 @@ async function resolveEmail({ label, defaultPaths, destPath, skipEmail, emailArg
|
|
|
141
141
|
while (true) {
|
|
142
142
|
const value = (await rl.question("Company email: ")).trim();
|
|
143
143
|
if (emailIsValid(value)) return value;
|
|
144
|
-
console.log("Invalid email.
|
|
144
|
+
console.log("Invalid Company email. Examples: xxxxx@huawei.com or xxxxx@h-partners.com");
|
|
145
145
|
}
|
|
146
146
|
} finally {
|
|
147
147
|
rl.close();
|
|
@@ -98,7 +98,7 @@ function Read-OhaiEmailUpdate {
|
|
|
98
98
|
if (Test-OhaiCompanyEmail $line) {
|
|
99
99
|
return $line.Trim()
|
|
100
100
|
}
|
|
101
|
-
Write-Host 'Invalid email.
|
|
101
|
+
Write-Host 'Invalid Company email. Examples: xxxxx@huawei.com or xxxxx@h-partners.com' -ForegroundColor Red
|
|
102
102
|
}
|
|
103
103
|
}
|
|
104
104
|
|
|
@@ -104,7 +104,7 @@ function Read-OhaiEmailUpdate {
|
|
|
104
104
|
if (Test-OhaiCompanyEmail $line) {
|
|
105
105
|
return $line.Trim()
|
|
106
106
|
}
|
|
107
|
-
Write-Host 'Invalid email.
|
|
107
|
+
Write-Host 'Invalid Company email. Examples: xxxxx@huawei.com or xxxxx@h-partners.com' -ForegroundColor Red
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
110
|
|
|
@@ -96,7 +96,7 @@ if [[ "$SKIP_EMAIL" -eq 0 ]]; then
|
|
|
96
96
|
USER_EMAIL_SAVE="${line//[[:space:]]/}"
|
|
97
97
|
break
|
|
98
98
|
fi
|
|
99
|
-
echo "Invalid email.
|
|
99
|
+
echo "Invalid Company email. Examples: xxxxx@huawei.com or xxxxx@h-partners.com" >&2
|
|
100
100
|
done
|
|
101
101
|
fi
|
|
102
102
|
fi
|