git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: replacing a bad commit

From
Jakub Narebski <jnareb@gmail.com>
Date
Feb 5, 2007, 20:38 UTC
Message-ID
<eq84ht$oaf$1@sea.gmane.org>
In-Reply-To
<20070205195332.GW14499@daga.cl>
Blu Corater wrote:
> On Mon, Feb 05, 2007 at 05:38:18PM +0100, Jakub Narebski wrote:
Show 16 quoted lines
>> Try using
>> 
>>   $ git rebase --onto A' A local
> 
> Thanks a lot, that did it.
> 
> I've got confused by the wording of the git-rebase man page. It says:
> 
>        <upstream>
>           Upstream branch to compare against
> 
> Which suggests to me that <upstream> must be a branch tip, and not a
> random commit, as seems to be the case (well, not random, but reachable
> from <branch> if I understand well). Also, the man page doesn't give any
> example of rebasing using a random commit as <upstream>, they all use
> branch tips which reinforced my wrong assumption.

Well, I think that two examples of using --onto should make it clear enough (especially second one), and both are quite similar to your situation I think.

But I agree that git-rebase(1) needs clarification. Do you volunteer? ;-)
-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
Previous: Blu CoraterNext: Blu Corater
Message 6 of 8 in “replacing a bad commit”
  1. Blu CoraterFeb 5, 2007
  2. Jakub NarebskiFeb 5, 2007
  3. Blu CoraterFeb 5, 2007
  4. Shawn O. PearceFeb 5, 2007
  5. Blu CoraterFeb 5, 2007
  6. Jakub NarebskiFeb 5, 2007
  7. Blu CoraterFeb 5, 2007
  8. Shawn O. PearceFeb 5, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.