feat: improve doctor update flow

This commit is contained in:
Peter Steinberger
2026-01-21 05:23:22 +00:00
parent 810374d648
commit 6180603ef4
4 changed files with 49 additions and 15 deletions

View File

@@ -250,7 +250,8 @@ export async function doctorCommand(
healthOk,
});
if (prompter.shouldRepair) {
const shouldWriteConfig = prompter.shouldRepair || configResult.shouldWriteConfig;
if (shouldWriteConfig) {
cfg = applyWizardMetadata(cfg, { command: "doctor", mode: resolveMode(cfg) });
await writeConfigFile(cfg);
runtime.log(`Updated ${CONFIG_PATH_CLAWDBOT}`);