Update and missing file in subrepo - a bug?

Michał Sznajder michalsznajder at gmail.com
Wed Feb 22 16:25:30 CST 2012


On Wed, Feb 22, 2012 at 11:17 PM, Matt Mackall <mpm at selenic.com> wrote:
> On Wed, 2012-02-22 at 22:55 +0100, Michał Sznajder wrote:
>> One of the users of THG reported [1] that update of the main
>> repository with a deleted file in the subrepo does not bring back file
>> in subrepo. Below is a way to reproduce this:
>>
>> hg init test
>> cd test
>> hg init subrepo
>> echo "subrepo = subrepo" > .hgsub
>> echo a > subrepo/file
>> hg -R subrepo commit --addremove --message "subrepo commit"
>> hg commit --addremove --message "commit"
>> # delete file
>> rm subrepo/file
>> hg update

This should be $ hg update -C I missed the most important part...

>> hg status --subrepos
>> ! subrepo/file
>>
>> IMHO this is wrong: file should be brought back. Should I file a bug?
>

hg help subrepos says that update "update restores the subrepos in the
state they were originally committed in target changeset."


More information about the Mercurial mailing list