How many flags are in filelog.flags() allowed?

Benoit Boissinot benoit.boissinot at ens-lyon.org
Sat Apr 24 16:14:37 CDT 2010


[adding Augie, I know he is interested in that topic]

On Sat, Apr 24, 2010 at 10:39:48PM +0200, Klaus Koch wrote:
> Hello, 
> 
> The manifest format allows several chars for file flags according to
> parse_manifest in parsers.c.
> 
> Consequently almost all calls of manifest.flags and context.flags ask
> whether some flag is in the result, like 'x' in files.flags(f).  On
> the other hand, in mercurial.commands.manifest and
> mercurial.patch.diff the result is used as key for a dictionary where
> just one char is defined: gitmode[man1.flags(a)].
> 
> So I wonder whether it is allowed to add additional flags, or if only
> the flags '', 'l', and 'x' are allowed?

If a manifest has more flags than 'l' and 'x', it's no longer a
mercurial repo, at least for now.
> 
> The reason why I am asking:
> At our company we would like to use Mercurial for repositories
> containing big files (ca. 0.5-1TiB all files together).
> 
> I have implemented an extension for handling such files by a simple
> wrapping of the dirstate.flagfunc to add a flag 'S' for files which
> are too big or match a certain file pattern.  Files which such a flag
> are then stored centrally.

We've been talking about using the same mechanism as planned for
lightweight copies to store bigfiles: implement a "fake" filelog that
would look for the data elsewhere.
> 
> Other solutions like BFiles and BigFiles do not scale for us, because
> they generate ignore patterns which take several seconds to generate
> (we have several hundreds of such files in our repo).

Can you explain more about that (for someone not very familiar with
bigfile)?

> Putting those files outside the repo/working dir does not work either,
> because they are either input data or their production requires
> several hours or days.

cheers,

Benoit

-- 
:wq


More information about the Mercurial-devel mailing list