[darcs-users] ANN: musdex
Max Battcher
me at worldmaker.net
Thu Mar 4 01:38:42 UTC 2010
Trent W. Buck wrote:
> Max Battcher <me at worldmaker.net> writes:
>
>> http://blog.worldmaker.net/2010/mar/03/storing-documents-version-control-musdex/
>>
>> [...] Basically, in darcs terms: its a prehook/posthook duo that
>> pre-record extracts the contents of given zip archives (which may be
>> .docx, or .odt files for instance) into a directory structure in a
>> darcs repository (adding the files to darcs as necessary) [...]
>>
>> I'd be interested if there are any questions, and/or finding out if
>> anyone finds this an interesting tool.
>
> Is this extensible to other blob types? I'm doing something similar for
> sqlite, but by main force rather than a wrapper.
Actually, that is an interesting idea for an extension to my work here.
I've thought about making the basic structure of musdex extensible, but
didn't have the need of it in this initial iteration.
What musdex does now:
Archive.zip -> _musdex/Archive.zip/* # each file in zip its own file
_musdex/Archive.zip/* -> Archive.zip
Presumably its not too much different to do:
Sqlite.db ~> _musdex/Sqlite.db/* # each database as SQL dump
_musdex/Sqlite.db/* ~> Sqlite.db
The transformation function is obviously a bit different, but much of
the configuration and checks for updates could be shared.
As with the zip archives you end up with a huge space utilization in
comparison to the original binary file (particularly because SQL dumps
can be extremely verbose), but you should gain some much nicer darcs
patches solely to a collection of text files as a benefit...
I'll post the darcs repository for musdex in just a bit, if you want to
play around with the code repository (although all the code can be seen
in the tarball on PyPI, considering this is Python).
I'll consider putting some sort of extension framework back on my TODO list.
--
--Max Battcher--
http://worldmaker.net
More information about the darcs-users
mailing list