On Sat, Mar 12, 2011 at 11:33 AM, Joshua Paine <[email protected]>wrote:

> > I think is interesting to know how to rollback a commit. I'm used to just
> add a new commit removing the changes. That way we keep the history (made a
> mistake, fixed the mistake)
>
> ... another option is to make the mistaken commit the start of a new branch
> named 'oops' or 'mistake' and immediately close that branch.
>

An example of doing exactly that can be seen in SQLite sources here:
http://www.sqlite.org/src/timeline?c=2010-10-01+15%3A11%3A09

I checked in a change that I thought was good.  But later I figured out it
was a bad idea, so I move the change onto the "mistake" branch, closed that
branch, and amended the check-in commit to explain why it was a bad idea.


-- 
D. Richard Hipp
[email protected]
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to