Fix Dolt backend init/daemon/doctor; prevent accidental SQLite artifacts; add integration tests; clean up lint (#1218)
* /{cmd,internal}: get dolt backend init working and allow issue creation
* /{website,internal,docs,cmd}: integration tests and more split backend fixes
* /{cmd,internal}: fix lint issues
* /cmd/bd/doctor/integrity.go: fix unable to query issues bug with dolt backend
* /cmd/bd/daemon.go: remove debug logging
This commit is contained in:
@@ -547,11 +547,14 @@ Examples:
|
||||
// Only do this when exporting to default JSONL path (not arbitrary outputs)
|
||||
// This prevents validatePreExport from incorrectly blocking on next export
|
||||
if output == "" || output == findJSONLPath() {
|
||||
beadsDir := filepath.Dir(finalPath)
|
||||
dbPath := filepath.Join(beadsDir, "beads.db")
|
||||
if err := TouchDatabaseFile(dbPath, finalPath); err != nil {
|
||||
// Log warning but don't fail export
|
||||
fmt.Fprintf(os.Stderr, "Warning: failed to update database mtime: %v\n", err)
|
||||
// Dolt backend does not have a SQLite DB file, so only touch mtime for SQLite.
|
||||
if _, ok := store.(*sqlite.SQLiteStorage); ok {
|
||||
beadsDir := filepath.Dir(finalPath)
|
||||
dbPath := filepath.Join(beadsDir, "beads.db")
|
||||
if err := TouchDatabaseFile(dbPath, finalPath); err != nil {
|
||||
// Log warning but don't fail export
|
||||
fmt.Fprintf(os.Stderr, "Warning: failed to update database mtime: %v\n", err)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user