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

Re: [PATCH RFC] rebase: respect --ff-only option

From
PWPhillip Wood <phillip.wood123@gmail.com>
Date
Jul 6, 2021, 13:52 UTC
Message-ID
<103eaf23-e55a-4583-bf02-0cebb78f00ae@gmail.com>
In-Reply-To
<CAMMLpeQG-eYgWTXyG0YzgN3U8QDASAtNFpxyXDFFPSVNzfw18g@mail.gmail.com>
Hi Alex
On 05/07/2021 20:48, Alex Henrie wrote:
Show 22 quoted lines
> On Mon, Jul 5, 2021 at 10:50 AM Junio C Hamano <gitster@pobox.com> wrote:
>>
>> Phillip Wood <phillip.wood123@gmail.com> writes:
>>
>>> Looking at origin/seen:builtin/pull.c we already check if we can
>>> fast-forward and unconditionally merge in that case irrespective of
>>> any '--rebase' option or pull.rebase config. It should be simple for
>>> pull to error out if '--ff-only' is given and we cannot fast-forward.
>>
>> Excellent.
>>
>> Even though teaching even more special case on the "git pull" side
>> makes me feel somewhat dirty, but I think it would be a small price
>> to pay, and the end result would save an useless fork whose sole
>> purpose is to make the integration step after fetch fail when "pull"
>> can easily tell, as you said, that it ought to fail, so overall it
>> would probably be a net win.
> 
> Okay, so it sounds like I should just scrap this patch and try again,
> after "pull: cleanup autostash check" is in master, with a patch that
> only modifies `git pull` and not `git rebase`. (Unless someone more
> experienced wants to take over, which would be fine by me.)

I don't think you need to wait, if necessary you could base your patches on top of that branch. Junio's latest what's cooking email said he was going to merge that branch into next so it is unlikely to change. In any case looking at the 'git diff origin/master origin/seen builtin/pull.c' I suspect the changes required won't conflict with that branch.

> Thanks anyway to Phillip and Ævar: Your feedback will help me write
> better patches in the future.
You're welcome, I look forward to reading your future patches
Best wishes
Phillip
> -Alex
> 
Previous: Ævar Arnfjörð BjarmasonNext: Felipe Contreras
Message 12 of 15 in “rebase: respect --ff-only option”
  1. rebase: respect --ff-only optionAlex Henrie, Jul 5, 2021
  2. Phillip WoodJul 5, 2021
  3. Junio C HamanoJul 5, 2021
  4. Felipe ContrerasJul 5, 2021
  5. Phillip WoodJul 5, 2021
  6. Felipe ContrerasJul 7, 2021
  7. Phillip WoodJul 5, 2021
  8. Junio C HamanoJul 5, 2021
  9. Junio C HamanoJul 5, 2021
  10. Alex HenrieJul 5, 2021
  11. Ævar Arnfjörð BjarmasonJul 6, 2021
  12. Phillip WoodJul 6, 2021
  13. Felipe ContrerasJul 7, 2021
  14. Ævar Arnfjörð BjarmasonJul 5, 2021
  15. Felipe ContrerasJul 5, 2021

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.