Our mercurial repository gets stuck when trying to update to an old branch which has a subrepo / revision pair that doesn't exist anymore.
abort: unknown revision '22e9bb6a6cd98be85b995f632b2f72d6298f9354'!
Is there any way to tell Mercurial to update to a revision or branch but not attempt to update the subrepos?
Does the subrepo still exist somewhere else? You can change the pointer to it using the [subpaths]
section, which provides a translation layer atop the locations in .hgsub
.
If it really doesn't exist anywhere you could so some deep magic like:
hg debugsetparent REVISION_YOU_WANT
cat /dev/null > .hgsub # put an empty .hgsub in place
hg commit .hgsub
hg update tip
That should create a new revision that's just like REVISION_YOU_WANT except it has an empty .hgsub file, so you can then update to it.
It'd be much better if you could find the subrepo at some new location and point to it with the subpaths.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With