[PATCH] add: only retrieve from dirstate.walk files that do exist on the filesystem

Matt Mackall mpm at selenic.com
Fri Dec 11 15:14:38 CST 2009


On Fri, 2009-12-11 at 11:40 +0900, Nicolas Dumazet wrote:
> # HG changeset patch
> # User Nicolas Dumazet <nicdumz.commits at gmail.com>
> # Date 1260498662 -32400
> # Node ID 4423def9e8ee48b373fd6253efef145cd32cdc1d
> # Parent  2b630e4c8f2f626f1e5d0f88646463968860f8ac
> add: only retrieve from dirstate.walk files that do exist on the filesystem
> 
> It does not make sense to match removed or missing files in this context.
> It should suppress a bogus hg add warning when adding a directory over
> a removed file.

Seems you're unaware of my dislike of '_'. I'd actually prefer to use
existing terminology, something like 'removed' (and obviously reversing
the sense of the switch). 

Does this patch properly distinguish between missing and removed states?
That is, if I delete a tracked file 'a' and try to add a new 'a/a' while
'a' is still tracked, does walk() return 'a'? It should.

Also, Greg's note about not adding new test scripts is good.

-- 
http://selenic.com : development and support for Mercurial and Linux




More information about the Mercurial-devel mailing list