Repository navigation
use new Archiver module where applicable - #13782
Conversation
14826e9 to
d00e93a
Compare
|
Thank you. Can the libarchive calls be moved to ZipWriter (or new ZipReader or ArcReader), to have simple methods to open, read and extract content of the supported archives? |
|
Straightforward ZipWriter calls are beautiful: koreader/frontend/apps/filemanager/filemanager.lua Lines 1624 to 1627 in 8b13b20 |
d00e93a to
5b8b4e4
Compare
I can in a subsequent PR, but note that the libarchive API is really not suited for random access, even for archives that support it (not solid). Which is why we have to reiterate over the entries in MuPDF has similar code, with some minor optimization to only "reset" the state (close & reopen the libarchive handle) when the entry wanted is before the current one. |
|
I would like to use it instead of the system unzip in readerui.lua and in the forthcoming back up / restore feature. |
|
Or we keep unzipping as is and use libarchive for rar only? |
|
I'll make another PR with an |
|
It will still be better than using unzip, especially on Android. |
5b8b4e4 to
d6a6dbe
Compare
Archiver module where applicable
d6a6dbe to
74f7ce0
Compare
|
Looks good, thanks. |
- ArchiveViewer: instead of using unzip and to support more formats (only CBR & RAR for now) - NewsDownloader & Wikipedia plugins: instead of using `ZipWriter` - device: re-implement `Device:unpackArchive` and get rid of device specific `untar` implementations - readerui: instead of using unzip for document provider detection
74f7ce0 to
9d2b2ac
Compare
- ArchiveViewer: instead of using unzip and to support more formats (only CBR & RAR for now) - NewsDownloader & Wikipedia plugins: instead of using `ZipWriter` - device: re-implement `Device:unpackArchive` and get rid of device specific `untar` implementations - readerui: instead of using unzip for document provider detection
For more supported formats (only CBR & RAR for now).
Depend on koreader/koreader-base#2086.
This change is