Write each backed-up original once and skip the precache (closes #106)
check / check (push) Successful in 49s

An original fetched for a backup is now written by the download writer
straight into the backup's originals/, and the content cache records it
there instead of keeping its own copy. One the cache already held is
still copied. `quak backup` opens its library with the thumbnail and
originals precache off, as the one-shot commands do.

Model: opus-5-5
This commit was merged in pull request #124.
This commit is contained in:
2026-09-23 08:48:02 +02:00
parent f52c77f155
commit ae76eb3f74
8 changed files with 109 additions and 30 deletions
+4
View File
@@ -380,10 +380,14 @@ export const backupCommand = async (
if (!client) return 1;
ctx.stderr.write("Starting backup...\n");
// The precache is off: the backup fetches what it needs, and must not
// also fill the cache with every thumbnail and the recent originals.
const lib = await Library.open({
client,
downloadDirectory: dir,
cacheDirectory: ctx.cacheDir,
precacheThumbnails: false,
precacheOriginals: false,
});
try {
const result = await lib.backup({