Re: [RFC/PATCH] Add a --nosort option to pack-objects
- From
Nicolas Pitre <nico@cam.org>
- Date
- Dec 7, 2007, 22:20 UTC
- Message-ID
- <alpine.LFD.0.99999.0712071707250.555@xanadu.home>
- In-Reply-To
- <20071207214627.GB13170@glandium.org>
On Fri, 7 Dec 2007, Mike Hommey wrote:
> As you can seen from my other message, I'm *actually* not sure this is > really material for git as a VCS. I will add documentation unrelated to > --nosort to pack-objects anyways.
Well, I have serious doubts about this patch in the first place.
I think it is simply unneeded.
If you want pack-objects not to change the sort order because you have some sorting of your own, externally implemented, then you simply have to run git-pack-objects feeding it the list of object SHA1s along with a tag of your own which will effectively impose the sorting you want, based on that tag.
Objects with the same tag will still be sorted amongst themselves which is still a good thing.
for example, you may have something like:
git rev-list --all --objects | sed -e 's|foo/logs/.*|LOGS|' | git pack-objects ...
This will effectively cluster all foo/logs/* files together for delta compression regardless of their actual name. Maybe that's what you really want?
Nicolas