chore: Cleaned up code.

This commit is contained in:
2026-06-15 09:26:48 -04:00
parent 4a26ee8145
commit ec96dff055
21 changed files with 445 additions and 294 deletions

View File

@@ -13,6 +13,7 @@ SyncEntry :: struct {
}
// TODO: Check for quiet failures.
// TODO: Support --format -f flags
cmd_sync :: proc(cmd: ^Command) {
db, db_ok := db_open(cmd.config_path)
if !db_ok {
@@ -26,11 +27,13 @@ cmd_sync :: proc(cmd: ^Command) {
}
defer delete(files)
// TODO: Set sane default size
results: [dynamic]SyncEntry
defer delete(results)
for &file in files {
old_path: string
old_path, _ = strings.clone(file.Path)
old_path, _ = strings.clone(file.Path, context.temp_allocator)
result, err_msg := db_sync(&db, &file)