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

Re: [PATCH v2 1/2] [GSOC] cherry-pick: fix bug when used with GIT_CHERRY_PICK_HELP

From
PWPhillip Wood <phillip.wood123@gmail.com>
Date
Aug 4, 2021, 10:10 UTC
Message-ID
<2e3e8379-99e3-521b-1666-30fcf0e7909b@gmail.com>
In-Reply-To
<CAOLTT8SkbNMcVocU9Lg3PfqTGHVEX8y27BMcP55HytfWH60w6g@mail.gmail.com>
On 04/08/2021 09:35, ZheNing Hu wrote:
Show 18 quoted lines
> Junio C Hamano <gitster@pobox.com> 于2021年8月4日周三 上午6:36写道:
>> Hmph, this is a bit troubling.  So has this been part of the
>> "published" behaviour since d7e5c0cb (Introduce CHERRY_PICK_HEAD,
>> 2011-02-19) that introduced this test, and there are people who are
>> relying on it?  IOW, should the resolution to the original problem
>> report have been "if it hurts, don't do it" (in other words, "setting
>> GIT_CHERRY_PICK_HELP will remove CHERRY_PICK_HEAD, so if you do not
>> want to get the latter removed, do not set the former")?
>>
> 
> You mean that cherry_pick with GIT_CHERRY_PICK_HELP suppresses
> CHERRY_PICK_HEAD is not even a bug?
> 
> It is reasonable for `git rebase -p` and  `git rebase -m` to delete
> CHERRY_PICK_HEAD when a conflict occurs, but it is not necessarily
> for git cherry-pick to delete it too. IOW, I suspect that instead of
> letting users
> not touch the trap here, it is better to remove the trap completely.

Looking at the history I think it is fair to conclude that GIT_CHERRY_PICK_HELP was introduced as a way to help people writing scripts built on top of 'git cherry-pick' like 'git rebase' that want to have a custom message and do not want to leave CHERRY_PICK_HEAD around if there are conflicts. I don't think it was intended as a way for users to change the help when cherry-picking and has never been documented as such. I think we'd be better to focus on improving the default help that cherry-pick prints as the second patch in this series does.

Best Wishes
Phillip
> Thanks.
> --
> ZheNing Hu
> 
Previous: ZheNing HuNext: Junio C Hamano
Message 12 of 32 in “[GSOC] cherry-pick: fix bug when used with GIT_CHERRY_PICK_HELP”
  1. 0/2 [GSOC] cherry-pick: fix bug when used with GIT_CHERRY_PICK_HELPZheNing Hu via GitGitGadget, Jul 31, 2021
  2. 2/2 [GSOC] cherry-pick: use better advice messageZheNing Hu via GitGitGadget, Jul 31, 2021
  3. Phillip WoodAug 1, 2021
  4. ZheNing HuAug 2, 2021
  5. 1/2 [GSOC] cherry-pick: fix bug when used with GIT_CHERRY_PICK_HELPZheNing Hu via GitGitGadget, Jul 31, 2021
  6. Phillip WoodAug 1, 2021
  7. ZheNing HuAug 2, 2021
  8. 0/2 [GSOC] cherry-pick: fix bug when used with GIT_CHERRY_PICK_HELPZheNing Hu via GitGitGadget, Aug 3, 2021
  9. 1/2 [GSOC] cherry-pick: fix bug when used with GIT_CHERRY_PICK_HELPZheNing Hu via GitGitGadget, Aug 3, 2021
  10. Junio C HamanoAug 3, 2021
  11. ZheNing HuAug 4, 2021
  12. Phillip WoodAug 4, 2021
  13. Junio C HamanoAug 4, 2021
  14. ZheNing HuAug 5, 2021
  15. 2/2 [GSOC] cherry-pick: use better advice messageZheNing Hu via GitGitGadget, Aug 3, 2021
  16. [GSOC] cherry-pick: use better advice messageZheNing Hu via GitGitGadget, Aug 5, 2021
  17. Phillip WoodAug 11, 2021
  18. ZheNing HuAug 13, 2021
  19. Junio C HamanoAug 13, 2021
  20. ZheNing HuAug 14, 2021
  21. Phillip WoodAug 17, 2021
  22. [GSOC] cherry-pick: use better advice messageZheNing Hu via GitGitGadget, Aug 14, 2021
  23. Junio C HamanoAug 14, 2021
  24. ZheNing HuAug 15, 2021
  25. [GSOC] cherry-pick: use better advice messageZheNing Hu via GitGitGadget, Aug 16, 2021
  26. Phillip WoodAug 18, 2021
  27. ZheNing HuAug 19, 2021
  28. ZheNing HuAug 19, 2021
  29. [GSOC] cherry-pick: use better advice messageZheNing Hu via GitGitGadget, Aug 19, 2021
  30. Junio C HamanoAug 19, 2021
  31. ZheNing HuAug 21, 2021
  32. [GSOC] cherry-pick: use better advice messageZheNing Hu via GitGitGadget, Aug 22, 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.