gvfs archive backend



Hi,

I've recently been investigating how hard it would be to provide a way
for Gnome's new gvfs virtual filesystem to "mount" archives [1]. The
general idea is that by treating an archive as a filesystem I would be
able to
- access single files inside the archive without the need to extract them
- be able to do archive managemenet tasks (like extraction or creation
of archives) inside my file manager (no need to learn a new
application.
- (and this is my blue sky goal) be able to extract single files from
archives on remote locations (after first mounting them from that
location of course) without the need to download the whole archive.

Of course, the first thing I did was look at existing tools and
libraries for that task. It seems Free archive management is in a very
poor state - at least on Ubuntu. Archiving applications like
file-roller just call out to command-line applications for editing
archives and is therefore constaint by the capabilities of these tools
(they only operate on files, for example).

It quickly became apparent that libarchive was a pretty neat archiving
tool, both because it was a sanely designed library, but also because
it was actually a packaging library that was in use (as opposed to for
example libzip). However, there were some things I wondered about and
thought you might have an opinion about.
- libarchive is stream oriented, while the way gvfs works would profit
from a way to get a list of files and then being able to say "extract
this archive entry". Of course we can just iterate once over the
archive and extract all metadata and then open the archive agan for
every read.
- libarchive has a focus on traditional unix archiving methods, such
as tar and cpio, while the files most users (and me, too) would be
interested in opening are likely more the windows-like types, such as
zip, iso or even rar. I wonder if pushing libarchive into that
direction is into your interest?
- libarchive does not support updating archives, only reading or
creating new ones. I have no clue what libarchive's goals are in that
direction? Would you consider adding support for that?
- What's your general opinion about using libarchive for this purpose.
It's quite a different thing from package manegement after all.

I think my first goal right now is to use libarchive and provide a
read-only way for accessing archives and then go from there.
One last question: Are you on IRC?

Cheers,
Benjamin


[1]: The API that "backends" (one backend implements a URI scheme,
like ftp, sftp etc) implement, can be seen at
http://svn.gnome.org/viewvc/gvfs/trunk/daemon/gvfsbackend.h?view=markup


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]