[PATCH 0 of 6] Recursive status and diff for subrepositories
Martin Geisler
mg at lazybytes.net
Wed Sep 1 15:50:28 CDT 2010
Tim Henigan <tim.henigan at gmail.com> writes:
> On Wed, Sep 1, 2010 at 11:24 AM, Martin Geisler <mg at lazybytes.net> wrote:
>> Tim Henigan <tim.henigan at gmail.com> writes:
>
> I am still trying different scenarios. One new question/issue: The new
> 'hg status' does not seem to handle nested subrepos. For example, if I
> have the following:
>
> top-level-repo/
> .hgsub (refers only to subrepo_1)
> .hgsubstate
> subrepo_1/
> .hgsub (refers only to subrepo_2)
> .hgsubstate
> subrepo_2/ this is a subrepo
>
> If subrepo_2 has a locally modified file, then calling 'hg status -S'
> from 'top-level-repo' does not show the modification. However, 'hg
> diff -S' does show the change. It appears that 'hg diff' knows to
> recurse into nested subrepos, but 'hg status' does not.
Ah, you're right! I actually had that on a list somewhere... thanks for
the reminder :-) It was fortunately easy to fix:
http://hg.lazybytes.net/subrepos-mq/rev/9aed6c32a8a0#l2.50
and I've now updated the test to use a two nested subrepositories. I've
updated the repositories...
If you run into more strange scenarios, then please see if you can turn
them into a small reproducible test and add them to
http://hg.lazybytes.net/subrepos/file/tip/tests/test-subrepo-recursion.t
Our new test format should be fairly easy to understand.
>> I guess we should instead put
>>
>> <X>+ subrepo
>>
>> into .hgsubstate -- the user will know that this means 'subrepo' is
>> at revision <X> but is dirty.
>
> I considered doing this for an extension I was writing, but was
> concerned that if I modified .hgsubstate to show some flag after
> <revision>, it would break other commands. I have not researched where
> .hgsubstate is used.
Yes, we will have to be sure that nothing reads back the <X>+ value.
I'll also have to look at where exactly this value is used.
--
Martin Geisler
Mercurial links: http://mercurial.ch/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20100901/54361c99/attachment.pgp>
More information about the Mercurial-devel
mailing list