partial revert

Martin Pool mbp at canonical.com
Tue Aug 23 10:51:40 UTC 2011


On 22 August 2011 18:06, Andreas Röhler <andreas.roehler at online.de> wrote:
> Hi,
>
> with several changes in a file, want to revert one of them but keep others.
>
> Learned so far shelving the good and reverting the remain would be the path.
> The setback AFAIU: with shelve I must deal with all the changes.
>
> OTOH as diff knows already every line, a command
>
> revert-partial from-line to-line
>
> seems within the range of possibilities.
>
> Maybe it exists already?

Hi Andreas,

The way I tend to deal with that is to run 'bzr diff --using meld', or
open the previous and edited versions of the files in vimdiff, and
then copy back the lines I want.  emacs vc integration also has some
tool to do this.

Putting something into the shelve ui to say "skip to line N" could be
useful, though generally users won't want to type line numbers...

Martin



More information about the bazaar mailing list