[PATCH] shelve: adds restoring newly created branch (issue5048)

Piotr Listkiewicz piotr.listkiewicz at gmail.com
Mon Feb 29 03:56:31 EST 2016


>
> So only in bare shelve restoring branch should take place?
>
> That's a proposal, lets sleep on it and see what other people think about
> it.


Does 'bare shelve' is shelve without specifying files/filesets?

If so, i have a problem with implementation. Probably the place to store if
shelve was 'bare' is .hg bundle file for given shelve or new bundle file.
In both cases i have no idea how to write this information in it.

Other idea would be to store this information in the new text file but this
seems like total overkill.

2016-02-26 14:58 GMT+01:00 Yuya Nishihara <yuya at tcha.org>:

> On Wed, 24 Feb 2016 17:52:25 +0100, Piotr Listkiewicz wrote:
> > >
> > > Right. I think we won't have to bump the version in this case.
> >
> >  Right, but what to do with reading old version of state file(without
> > restoring branch information) with newer client?
>
> Not restoring the branch, as the branch information isn't stored in the old
> state file. fp.readline() will return ''.
>
> > I would bump version of
> > file to mark that file has information about branch in last line, but
> older
> > version of mercurial would crash because it checks whether version of
> file
> > is equals version in sources.
>
> If both old/new clients can read old/new state files, we don't need to bump
> the version.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mercurial-scm.org/pipermail/mercurial-devel/attachments/20160229/e6ca559e/attachment.html>


More information about the Mercurial-devel mailing list