Add bd migrate command for database upgrades (bd-164)
- Implement bd migrate command with detection, version checking, and cleanup - Update daemon to suggest bd migrate for version mismatches - Enhance CLI version warnings to recommend bd migrate - Add comprehensive tests for migration scenarios - Document migration workflow in QUICKSTART.md and AGENTS.md Completes bd-164 and epic bd-159 Amp-Thread-ID: https://ampcode.com/threads/T-34ea4682-8c48-44c2-8421-dc40f867773b Co-authored-by: Amp <amp@ampcode.com>
This commit is contained in:
@@ -1032,7 +1032,8 @@ func checkVersionMismatch() {
|
||||
} else if cmp > 0 {
|
||||
// Binary is newer than database
|
||||
fmt.Fprintf(os.Stderr, "%s\n", yellow("⚠️ Your binary appears NEWER than the database."))
|
||||
fmt.Fprintf(os.Stderr, "%s\n\n", yellow("⚠️ The database will be upgraded automatically."))
|
||||
fmt.Fprintf(os.Stderr, "%s\n", yellow("⚠️ Run 'bd migrate' to check for and migrate old database files."))
|
||||
fmt.Fprintf(os.Stderr, "%s\n\n", yellow("⚠️ The current database version will be updated automatically."))
|
||||
// Update stored version to current
|
||||
_ = store.SetMetadata(ctx, "bd_version", Version)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user