On Thu, 20 Oct 2011 17:28:27 +0200 jos van kesteren <[email protected]> wrote:
[...] >>> Even that is not necessarily true. You can't merge binary files >>> like text files -- sure. But it doesn't mean that for a specific >>> binary format, a merge algorithm isn't possible. Consider ODF >>> documents for a moment. A merge program could extract the zip >>> archive, do a *textual* merge on the XML files and zip the result >>> up again. It works well for many use cases. [...] > Since ODF documents can be unzipped, and their XML contents are text > anyway, why not make a commit program (instead of a merge program) > that unzips the ODF and > stores the XML in the repo ? Note that there are some problems: 1) Zipping them back is not that trivial [1] which means you have to use specialized "uncommit" program to properly reassemble such containers. 2) ODF container stores several files in several directories, so as soon as you unpacked it, it's not just a single file anymore, so you have to invent a way to somehow treat the files from this container as a single entity when they are stored in a DVCS. (And in some or a parallel thread here someone confirmed Fossil does only tag commits, not files.) 3) The XML files in ODF containers, while human-readable, are still autogenerated. The XML format is indeed intended to increase accessibility of the content, but innocent changes in the document from the point of view of the user who made them can result in rather "interesting" changes in the content files. For instance, ODT (spreadsheets), as far as I know, do not allow you to directly attach a property to a cell which would indicate that cell has red background color; instead the editor will create a special style inculding that color info (unless there's no already existing matching style) and attach it to that cell. By this I'm suggesting that diffing contents of two ODF files using only their unpacked contents could not be that straigforward to comprehend. 1. http://tanguy.ortolo.eu/blog/article24/ _______________________________________________ fossil-users mailing list [email protected] http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

