feat(hal): expose rename() on HalStorage

Forward SDCardManager::rename() through the HAL layer for
file/directory move operations needed by book archiving.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
cottongin
2026-02-21 02:50:27 -05:00
parent 3d51dfeeb7
commit f443f5dde0
2 changed files with 3 additions and 0 deletions

View File

@@ -38,6 +38,8 @@ bool HalStorage::remove(const char* path) { return SDCard.remove(path); }
bool HalStorage::rmdir(const char* path) { return SDCard.rmdir(path); } bool HalStorage::rmdir(const char* path) { return SDCard.rmdir(path); }
bool HalStorage::rename(const char* path, const char* newPath) { return SDCard.rename(path, newPath); }
bool HalStorage::openFileForRead(const char* moduleName, const char* path, FsFile& file) { bool HalStorage::openFileForRead(const char* moduleName, const char* path, FsFile& file) {
return SDCard.openFileForRead(moduleName, path, file); return SDCard.openFileForRead(moduleName, path, file);
} }

View File

@@ -29,6 +29,7 @@ class HalStorage {
bool exists(const char* path); bool exists(const char* path);
bool remove(const char* path); bool remove(const char* path);
bool rmdir(const char* path); bool rmdir(const char* path);
bool rename(const char* path, const char* newPath);
bool openFileForRead(const char* moduleName, const char* path, FsFile& file); bool openFileForRead(const char* moduleName, const char* path, FsFile& file);
bool openFileForRead(const char* moduleName, const std::string& path, FsFile& file); bool openFileForRead(const char* moduleName, const std::string& path, FsFile& file);