feat: add BookManager utility and RecentBooksStore::clear()
BookManager provides static functions for archive/unarchive/delete/ deleteCache/reindex operations on books, centralizing cache path computation and file operations. Archive preserves directory structure under /.archive/ and renames cache dirs to match new path hashes. RecentBooksStore: :clear() added for bulk cache clearing use case. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -47,6 +47,11 @@ void RecentBooksStore::removeBook(const std::string& path) {
|
||||
}
|
||||
}
|
||||
|
||||
void RecentBooksStore::clear() {
|
||||
recentBooks.clear();
|
||||
saveToFile();
|
||||
}
|
||||
|
||||
void RecentBooksStore::updateBook(const std::string& path, const std::string& title, const std::string& author,
|
||||
const std::string& coverBmpPath) {
|
||||
auto it =
|
||||
|
||||
Reference in New Issue
Block a user