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

Re: [PATCH] submodule--helper.c: add only-active to foreach

From
Junio C Hamano <gitster@pobox.com>
Date
May 13, 2020, 20:35 UTC
Message-ID
<xmqqwo5fshe0.fsf@gitster.c.googlers.com>
In-Reply-To
<83b37142-f6f0-2f5d-e92c-de3891e8fe18@gmail.com>
Guillaume Galeazzi <guillaume.galeazzi@gmail.com> writes:
> The difference is that you repeat twice the same flag. Sometime
> repeating a flag overwrite the previous value,...

I already said I was *not* suggesting a concrete syntax. The more important point was to make us realize that we need to think outside of "active-only" and make sure we can support other kinds of selection criteria for submodules.

So whatever syntax you would want to use to specify more than one, combine, and negate, I do not care too deeply, as long as it is in line with what we use in the other parts of the system ;-).

> Regarding previous example, it use '!' to negate the value. Not all
> people know the meaning of it.

We mark the bottom commit by negating with ^ (e.g. "git log ^maint master"), we mark "not ignored" entries by prefixing with '!' in .gitignore, we mark "unset" entries by prefixing with '-' in .gitattributes (the '!' prefix is used to mark "unspecified" entries), and "rev-list --boundary" output uses '~' prefix to mean "this is not part of the range".

So there are many one-letter "not" we already use, and there seem to be no rule to pick which one in what context X-<.

So spelling out "--no-blah" to mean "not with blah" is probably a good thing to do (especially if readers do not mind being English centric).

Previous: Guillaume GaleazziNext: Guillaume Galeazzi
Message 14 of 22 in “submodule--helper.c: add only-active to foreach”
  1. submodule--helper.c: add only-active to foreachGuillaume G. via GitGitGadget, May 10, 2020
  2. Shourya ShuklaMay 10, 2020
  3. Guillaume GaleazziMay 10, 2020
  4. Eric SunshineMay 10, 2020
  5. Guillaume GaleazziMay 15, 2020
  6. Shourya ShuklaMay 12, 2020
  7. Guillaume GaleazziMay 15, 2020
  8. Junio C HamanoMay 15, 2020
  9. Guillaume GaleazziMay 15, 2020
  10. Junio C HamanoMay 12, 2020
  11. Guillaume GaleazziMay 13, 2020
  12. Junio C HamanoMay 13, 2020
  13. Guillaume GaleazziMay 13, 2020
  14. Junio C HamanoMay 13, 2020
  15. Guillaume GaleazziMay 15, 2020
  16. 0/3 submodule--helper.c: add only-active to foreachGuillaume G. via GitGitGadget, May 17, 2020
  17. 1/3 submodule--helper.c: add active to foreachGuillaume Galeazzi via GitGitGadget, May 17, 2020
  18. 3/3 submodule--helper.c: add branch to foreachGuillaume Galeazzi via GitGitGadget, May 17, 2020
  19. 2/3 submodule--helper.c: add populated to foreachGuillaume Galeazzi via GitGitGadget, May 17, 2020
  20. Junio C HamanoMay 17, 2020
  21. Guillaume GaleazziMay 17, 2020
  22. Guillaume GaleazziAug 18, 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.