[#3] Backup restore UI #3
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
_make_backup()already writes rotating timestamped backups (.bcc_backups/<name>.<timestamp>.json, capped atMAX_BACKUPS=15) on every save. But there is no way to browse or restore one from the GUI — you have to find the file manually. Research repeatedly surfaces "config got corrupted / Claude won't launch after I edited it" as a common failure mode, which is exactly what these backups exist to fix, but the fix is currently inaccessible.Proposed solution
A Restore from backup… action per profile that:
.bcc_backups/, sorted newest-first, with human-readable timestamps.write_config()atomic-write path — so restoring itself creates a new backup of the pre-restore state.Core logic (listing, diffing, preview generation) lives in
bcc_core.py; the dialog lives inbcc.py.Acceptance criteria
Relevant code
bcc_core.py::_make_backup(line 207)bcc_core.py::write_config(line 226)bcc_core.py::BACKUP_DIRNAME,MAX_BACKUPSconstants