Uncommit a single file?

John Meinel john at arbash-meinel.com
Tue Apr 9 05:10:48 UTC 2013

For what you want, you really have to rewrite history. All of the
intermediate commits specifically reference the "bad" version of the file.
So you have to create a new history that doesn't. You can look into the
bzr-rewrite plugin for help in doing it.

Though in our experience, just doing the revert+commit is easier and more
relevant for people who might want to know what is going on. (Rewiring
history means you have revisions that weren't actually what someone was
using, etc.)

On Apr 9, 2013 12:53 AM, <ckalisiak at attotech.com> wrote:

> Hello again,
> Thanks everyone for the help that has been provided in dealing with our
> branches. I have another question that I haven't been able to figure out an
> answer to. One of our branches has a problem with the commit of one of the
> files, a half-dozen revisions ago. No other changes to that file have been
> made, but now that we're performing a merge, it's giving us some grief.
> I'd like to be able to uncommit that particular file to the revision
> immediately prior to the last commit, to effectively forget that the commit
> of that particular file ever happened, while leaving the rest of the branch
> metadata intact.
> If I just simply revert and commit, the file will look correct, but
> obviously the metadata will still reflect the past commit.
> Is there a way to perform this operation?
> Thanks,
> Chris
> --
> Chris Kalisiak
> Senior Embedded Systems Engineer
> ATTO Technology, Inc.
> Phone:  +1.716.691.1999 ext. 274
> Fax +1.716.691.9353
> "Powering the World's Networks & Storage"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/bazaar/attachments/20130409/ae2ab217/attachment.html>

More information about the bazaar mailing list