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

Re: [PATCH] git: --no-lazy-fetch option

From
Junio C Hamano <gitster@pobox.com>
Date
Feb 16, 2024, 17:22 UTC
Message-ID
<xmqq1q9cl3xv.fsf@gitster.g>
In-Reply-To
<xmqqv86pslos.fsf@gitster.g>
Junio C Hamano <gitster@pobox.com> writes:
> Yuck, I was hoping that we can get away with the tiny change only
> for builtins,but you're right.

Here is a preliminary clean-up only for Documentation. Will not be queuing before the final, but just so that I won't forget.

------- >8 ------------- >8 ------------- >8 -------
Subject: [PATCH] git: document GIT_NO_REPLACE_OBJECTS environment variable

This variable is used as the primary way to disable the object replacement mechanism, with the "--no-replace-objects" command line option as an end-user visible way to set it, but has not been documented.

The original reason why it was left undocumented might be because it was meant as an internal implementation detail, but the thing is, that our tests use the environment variable directly without the command line option, and there certainly are folks who learned its use from there, making it impossible to deprecate or change its behaviour by now.

Add documentation and note that for this variable, unlike many boolean-looking environment variables, only the presence matters, not what value it is set to.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
 Documentation/git.txt | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
diff --git c/Documentation/git.txt i/Documentation/git.txt
index 95f451b22b..2f1cb3ef4e 100644
--- c/Documentation/git.txt
+++ i/Documentation/git.txt
@@ -174,8 +174,10 @@ If you just want to run git as if it was started in `<path>` then use
 	directory.
 
 --no-replace-objects::
-	Do not use replacement refs to replace Git objects. See
-	linkgit:git-replace[1] for more information.
+	Do not use replacement refs to replace Git objects.
+	This is equivalent to exporting the `GIT_NO_REPLACE_OBJECTS`
+	environment variable with any value.
+	See linkgit:git-replace[1] for more information.
 
 --no-lazy-fetch::
 	Do not fetch missing objects from the promisor remote on
Previous: Junio C HamanoNext: Junio C Hamano
Message 7 of 20 in “git: --no-lazy-fetch option”
  1. git: --no-lazy-fetch optionJunio C Hamano, Feb 8, 2024
  2. Linus ArverFeb 13, 2024
  3. Linus ArverFeb 13, 2024
  4. Junio C HamanoFeb 13, 2024
  5. Jeff KingFeb 15, 2024
  6. Junio C HamanoFeb 15, 2024
  7. Junio C HamanoFeb 16, 2024
  8. git: extend --no-lazy-fetch to work across subprocessesJunio C Hamano, Feb 16, 2024
  9. Linus ArverFeb 16, 2024
  10. Junio C HamanoFeb 16, 2024
  11. Linus ArverFeb 16, 2024
  12. Jeff KingFeb 17, 2024
  13. Junio C HamanoFeb 27, 2024
  14. Jeff KingFeb 27, 2024
  15. Junio C HamanoFeb 27, 2024
  16. Jeff KingMar 7, 2024
  17. Junio C HamanoMar 7, 2024
  18. Jeff KingFeb 17, 2024
  19. Linus ArverMar 9, 2024
  20. Linus ArverFeb 15, 2024

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.