Two things that bzr makes hard :-(
Matthieu Moy
Matthieu.Moy at imag.fr
Wed Jun 4 15:03:09 BST 2008
Robert Collins <robertc at robertcollins.net> writes:
>> 2) "Roll back to revision X"
>>
>> Sometimes I want to roll my branch and its checkout back to a
>> particular revision. The resulting branch and tree should be
>> the same as if I'd checked it out with -r.
>>
>> $ bzr revert -r
>>
>> Rolls the working tree back, but leaves the commits so the
>> rollback appears as a great big diff.
>>
>> $ bzr uncommit -r
>>
>> Rolls the commits back, but leaves the working tree changes as a
>> great big diff
>>
>> I want both in one!
>
> $ bzr update -r
> is the conceptual command.
>
> bug https://bugs.edge.launchpad.net/bzr/+bug/45719 lists this.
I don't think this is what the OP expects.
update -r changes the working tree, but keeps history intact (so that
you can later update back to the tip). revert+uncommit is what "git
reset --hard" does in git, it discards history and the working tree.
Note that you shouldn't do that on a published branch. Or anybody
having branched/merged the commits you throw away will be in trouble
when trying to merge with you later.
--
Matthieu
More information about the bazaar
mailing list