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

Re: [GSOC PATCH v2 1/2] environment: remove the global variable 'merge_log_config'

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 11, 2025, 16:13 UTC
Message-ID
<xmqqikit3kgo.fsf@gitster.g>
In-Reply-To
<076c19ae-58fc-4823-9679-1d5fe6e46211@gmail.com>
Phillip Wood <phillip.wood123@gmail.com> writes:
Show 12 quoted lines
> Hi Ayush
>
> On 11/08/2025 00:45, Ayush Chandekar wrote:
>> The global variable 'merge_log_config', set via the "merge.log" or
>> "merge.summary" settings, is only used in 'cmd_fmt_merge_msg()' and
>> 'cmd_merge()' to adjust the 'shortlog_len' variable.
>> Remove 'merge_log_config' globally and localize it in
>> 'cmd_fmt_merge_msg()' and 'cmd_merge()'. Set its value by passing it in
>> 'fmt_merge_msg_config()' by passing its pointer to the function via the
>> callback parameter.
>
> This looks like a good solution

When fmt_merge_msg_config() needs to read more stuff, the callback parameter may have to be updated, but this will do for now.

Thanks.
Previous: Phillip WoodNext: Ayush Chandekar
Message 17 of 19 in “builtin/fmt-merge-msg: remove dependency on global variables and 'the_repository'”
  1. 0/2 builtin/fmt-merge-msg: remove dependency on global variables and 'the_repository'Ayush Chandekar, Jul 29, 2025
  2. 1/2 environment: remove the global variable 'merge_log_config'Ayush Chandekar, Jul 29, 2025
  3. Junio C HamanoJul 29, 2025
  4. Ayush ChandekarJul 29, 2025
  5. Junio C HamanoJul 29, 2025
  6. Phillip WoodJul 29, 2025
  7. Ayush ChandekarJul 29, 2025
  8. Phillip WoodJul 30, 2025
  9. 2/2 builtin/fmt-merge-msg: stop depending on 'the_repository'Ayush Chandekar, Jul 29, 2025
  10. Junio C HamanoJul 29, 2025
  11. Ayush ChandekarJul 29, 2025
  12. Junio C HamanoJul 29, 2025
  13. Ayush ChandekarAug 10, 2025
  14. 0/2 builtin/fmt-merge-msg: remove dependency on global variables and 'the_repository'Ayush Chandekar, Aug 10, 2025
  15. 1/2 environment: remove the global variable 'merge_log_config'Ayush Chandekar, Aug 10, 2025
  16. Phillip WoodAug 11, 2025
  17. Junio C HamanoAug 11, 2025
  18. Ayush ChandekarAug 11, 2025
  19. 2/2 builtin/fmt-merge-msg: stop depending on 'the_repository'Ayush Chandekar, Aug 10, 2025

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.