How do I update a working tree to an old revision?
nick.allen at onlinehome.de
Sat Jul 18 09:28:39 BST 2009
> It changes the file contents of working tree to a certain revision.
> Whether you choose to commit that is entirely up to you.
Ah ok - that's exactly what I need ;-)
> > misunderstanding of what revert -r does on my behalf. It sounds like
> > what I would expect update -r to do.
> The main difference is that update -r changes the tip revision of the
> tree and revert does not. This means that if you update -r and run
> status or diff, no changes will be shown. It also means that you can't
> > I guess I would use merge command
> > to make changes to working tree that revert to an old revision then?
> Once you have identified the revision that introduced the bug (I'll call
> it $BAD_REVISION), you can "bzr revert" to restore your working tree
> files to what they were before you started looking for the bug.
> Normally, you would fix the bug, but you can also use "bzr merge . -r
> $BAD_REVISION..before:$BAD_REVISION" to remove the changes introduced by
> $BAD_REVISION, and commit the result.
> Is that what you mean?
Yeah thanks for that. I think it would be more intuitive if revert had a
-c option to revert the changes in a given revision. It would do the
same thing as a reverse revision range merge. So you would just do:
bzr revert -c $BAD_REVISION
Perhaps it could also take a list of bad revisions?
More information about the bazaar