git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Phillip Wood <phillip.wood123@gmail.com>
To: Jarno Suni <jarno.ilari.suni@gmail.com>, git@vger.kernel.org
Subject: Re: error: could not parse 'Drop' when rebasing
Date: Wed, 26 Mar 2025 10:20:39 +0000	[thread overview]
Message-ID: <3b09226a-8281-4560-aa23-74aeaa3ff41a@gmail.com> (raw)
In-Reply-To: <CAOqj8L0hknJ2aYGSmXdUvRgzHZRWBTMgSvywGpc=TUZL-Dqnmw@mail.gmail.com>

Hi Jarno

On 26/03/2025 07:17, Jarno Suni wrote:
> git version 2.43.0
> 
> $ git rebase --edit-todo
> error: could not parse 'Drop'
> error: invalid line 1: r Drop option --figure-soname-bumps

It appears that the object id for the commit got deleted when the 
command was changed from "pick" to "reword" and so git does not know 
which commit this line is referring to. The commit subject is there for 
the benefit of the user not for git - after all many commits could share 
the same subject.

Best Wishes

Phillip
  > error: could not parse 'Drop'
> error: invalid line 1: p Drop option --figure-soname-bumps
> You can fix this with 'git rebase --edit-todo' and then run 'git
> rebase --continue'.
> Or you can abort the rebase with 'git rebase --abort'.
> 
> "Drop option --figure-soname-bumps" is the commit message.
> Git doesn't seem to accept any command for the commit. First I tried command d.
> 
> Workaround:
> I did `git rebase --abort`. Started new rebase, used r command for the
> commit to rename it to not have "Drop" as first word. After that I can
> rebase again and use d command for the commit.
> 


  reply	other threads:[~2025-03-26 10:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-26  7:17 error: could not parse 'Drop' when rebasing Jarno Suni
2025-03-26 10:20 ` Phillip Wood [this message]
     [not found]   ` <CAOqj8L1Ammwp07ju2dweVhRVdkTv=hROaDjcoXbxJj8xNq8Gtg@mail.gmail.com>
2025-03-26 15:12     ` Phillip Wood

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3b09226a-8281-4560-aa23-74aeaa3ff41a@gmail.com \
    --to=phillip.wood123@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=jarno.ilari.suni@gmail.com \
    --cc=phillip.wood@dunelm.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).