Not a holy war - just some salient facts

Greg Ward greg-hg at gerg.ca
Wed Apr 14 14:16:25 CDT 2010


On Wed, Apr 14, 2010 at 12:10 PM, Tom Widmer <tom.widmer at googlemail.com> wrote:
> Because of the filelog format, if you rename every file in a HG repo, you
> double the repo's size.

That's only true if every tracked file is uncompressible and has
exactly one revision.  What happens when you rename is that hg copies
the last revision of the old filelog to the new filelog.  Since it's a
revision in a filelog, the data is compressed.  And it's only revision
that gets copied.

It's obviously still suboptimal -- for example, if the first rev of
the new filelog could reference the rev from which it was copied, it
could be a delta rather than a compressed copy.  But it's not as bad
as you say.

Greg


More information about the Mercurial mailing list