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

Re: [Q] rebase -i: turn "pick" to "edit", make no change, what should happen?

From
Junio C Hamano <gitster@pobox.com>
Date
May 17, 2024, 15:17 UTC
Message-ID
<xmqqh6ewmpr0.fsf@gitster.g>
In-Reply-To
<ZkcH-LAkLkf_wvfq@tanuki>
Patrick Steinhardt <ps@pks.im> writes:
> I quite frequently use "edit" just to inspect commits, stop at random
> points in the history, run tests and whatnot. So this would be a UX
> regression for me because I do not want to change commit messages and
> don't want to be bothered.

I sometimes (ab)use the "edit" exactly like that myself, so a simple-minded unconditional change of behaviour would be a UX regression to me as well.

> With the introduction of the "break" command you can certainly argue
> that "edit" is the wrong command to use in my case. Muscle memory is
> hard to retrain though :)

Yes, with a vim macro or its Emacs equivalent, it should be just as easy as doing "s/^pick /edit /" to insert "break" after every line that begins with "pick ", but "just as easy" is still an unwanted forced change to the end-users. If I really wanted to, the right and only way out is to introduce a new insn similar to "edit" but behaves more like what I said earlier.

Thanks.
Previous: Sean AllredNext: Marc Branchaud
Message 7 of 9 in “[Q] rebase -i: turn "pick" to "edit", make no change, what should happen?”
  1. Junio C HamanoMay 16, 2024
  2. Sean AllredMay 16, 2024
  3. Junio C HamanoMay 17, 2024
  4. Patrick SteinhardtMay 17, 2024
  5. Dragan SimicMay 17, 2024
  6. Sean AllredMay 17, 2024
  7. Junio C HamanoMay 17, 2024
  8. Marc BranchaudMay 17, 2024
  9. Junio C HamanoMay 17, 2024

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.