Re: [PATCH 2/2] Add keyword unexpansion support to convert.c

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

 



Nicolas Pitre wrote:
On Tue, 17 Apr 2007, David Lang wrote:


I've
been told in the past that once .gitattributes is in place then the hooks for
the crlf stuff can be generalized to allow for calls out to custom code to do
this sort of thing.

And I agree that this is a perfectly sensible thing to do. The facility should be there for you to apply any kind of transformation with external tools on data going in or out from Git. There are good and bad things you can do with such a facility, but at least it becomes your responsibility to screw^H^H^H^Hfilter your data and not something that is enforced by Git itself.


Nicolas

One of the examples that has been given in the past has been taking a zipped OpenDocumentFormat file, unzipping it to its component parts, and then committing the individual files rather than the aggregate.

But I can't figure out how this might work.

One idea is to store the binary ODF file in the index (and in the packs, etc) as a directory with the individual text (and other) files as entries within that directory. Then, when various git operations want to use the directory, the operation is redirected via an attribute match to an external script that knows how to checkout an ODF "directory", or diff an ODF "directory", etc.

Or similarly, when checking an "ODF" file in, the attribute would lead to an appropriate script creating the "tree" of individual files.

Does this sound workable?

Rogan
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]