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

Re: git rebase interactive: usability issue

From
Dmitry Potapov <dpotapov@gmail.com>
Date
Jun 26, 2008, 11:35 UTC
Message-ID
<20080626113549.GF5737@dpotapov.dyndns.org>
In-Reply-To
<7vbq1ovpl7.fsf@gitster.siamese.dyndns.org>
Hi Junio,

Please, do not apply my previous patch. I just realized that it will break the following sequence of commands when you are stopped on a conflicting commit during rebase:

$ edit file $ git add file $ git commit $ git commit --amend

I don't see a good solution right now. Perhaps, the better approach will be to remove the suggestion of using "git commit --amend" and instead to recommend to use "git add" to add your changes and then run "git rebase --continue". This works regardless whether you stop on the "edit" mark or conflict. The only problem with that is what if the user actually wanted to edit the commit message. Currently, saying just "git rebase --continue" without adding anything will not allow you to edit the commit message.

After studying git-rebase script, I noticed that it always commit with the --no-verify option. It makes sense for those commits that were just "pick" but IMHO those commits that were edited by users probably should be commited in the normal way, so the pre-commit hook can ensure that your changes are okay.

Dmitry
Previous: Avery PennarunNext: Theodore Tso
Message 5 of 7 in “git rebase interactive: usability issue”
  1. Dmitry PotapovJun 25, 2008
  2. Johannes SchindelinJun 26, 2008
  3. Junio C HamanoJun 26, 2008
  4. Avery PennarunJun 26, 2008
  5. Dmitry PotapovJun 26, 2008
  6. Theodore TsoJun 26, 2008
  7. don't allow 'commit --amend' during rebase conflict resolutionDmitry Potapov, Jun 26, 2008

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.