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

Re: [PATCH] completion: use native ZSH array pattern matching

From
Junio C Hamano <gitster@pobox.com>
Date
May 28, 2020, 16:14 UTC
Message-ID
<xmqq8shc3ukc.fsf@gitster.c.googlers.com>
In-Reply-To
<pull.645.git.1590520398132.gitgitgadget@gmail.com>
"Marco Trevisan via GitGitGadget" <gitgitgadget@gmail.com> writes:
Show 6 quoted lines
> From: =?UTF-8?q?Marco=20Trevisan=20=28Trevi=C3=B1o=29?= <mail@3v1n0.net>
>
> When clearing the builtin operations on re-sourcing in the ZSH case we
> can use the native ${parameters} associative array keys values to get
> the currently `__gitcomp_builtin_*` operations using pattern matching
> instead of using sed.

"We can" may be a statement of fact, but by itself it does not make a convincing argument why we should have this change in our codebase.

Is this change about correctness? Is it about performance? Or something else?

If it is about correctness, "the current code fails in this way given this input, but with the new code the breakage is gone" would be a good justification to give in the proposed log message. If it is about performance, of course a measured performance numbers would make an objective justification that is hard to argue with, especially if you can convince people that the patch does not change the behaviour in any negative way. If it is about something else, well, there would be an appropriate way to justify the change, depending on what it is ;-)

Thanks.
Previous: Junio C Hamano
Message 8 of 8 in “completion: use native ZSH array pattern matching”
  1. completion: use native ZSH array pattern matchingMarco Trevisan via GitGitGadget, May 26, 2020
  2. brian m. carlsonMay 26, 2020
  3. Carlo Marcelo Arenas BelónMay 27, 2020
  4. brian m. carlsonMay 28, 2020
  5. Junio C HamanoMay 28, 2020
  6. brian m. carlsonMay 28, 2020
  7. Junio C HamanoMay 28, 2020
  8. Junio C HamanoMay 28, 2020

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.