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

Re: [PATCH v2 4/5] doc: be more precise on (fetch|push).recurseSubmodules

From
Junio C Hamano <gitster@pobox.com>
Date
Mar 3, 2020, 22:05 UTC
Message-ID
<xmqqo8td6qmm.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<20200303170740.1879432-5-damien.olivier.robert+git@gmail.com>
Damien Robert <damien.olivier.robert@gmail.com> writes:
Show 16 quoted lines
> diff --git a/Documentation/config/fetch.txt b/Documentation/config/fetch.txt
> index f11940280f..8f716809f9 100644
> --- a/Documentation/config/fetch.txt
> +++ b/Documentation/config/fetch.txt
> @@ -2,10 +2,12 @@ fetch.recurseSubmodules::
>  	This option can be either set to a boolean value or to 'on-demand'.
>  	Setting it to a boolean changes the behavior of fetch and pull to
>  	unconditionally recurse into submodules when set to true or to not
> -	recurse at all when set to false. When set to 'on-demand' (the default
> -	value), fetch and pull will only recurse into a populated submodule
> +	recurse at all when set to false. When set to 'on-demand', 
> +	fetch and pull will only recurse into a populated submodule
>  	when its superproject retrieves a commit that updates the submodule's
>  	reference.
> +	If not set, it fallbacks to the value of `submodule.recurse`, and
> +	if both are not set the default value is 'on-demand'.

I do not think "fallback" is a single-word verb. If you must use the phrase, "it falls back to the value of ...", but I personally prefer to give the simplest case first and then its variants second (i.e. if you do not do anything, this is what you get, and then if you do this thing, this other thing happens).

In other words:
	If not set, 'on-demand' is used by default, unless
	'submodule.recurse' is set, in which case it is used.

But in this case it is so obvious that it would not be necessary to add ", in which case it is used" at the end.

Show 11 quoted lines
> diff --git a/Documentation/config/push.txt b/Documentation/config/push.txt
> index 54871f8213..2a5250cf5c 100644
> --- a/Documentation/config/push.txt
> +++ b/Documentation/config/push.txt
> @@ -112,3 +112,6 @@ push.recurseSubmodules::
>  	is 'no' then default behavior of ignoring submodules when pushing
>  	is retained. You may override this configuration at time of push by
>  	specifying '--recurse-submodules=check|on-demand|no'.
> +	If not set, it fallbacks to the value of `submodule.recurse` (where
> +	a 'true' value means 'on-demand'), and if both are not set the
> +	default value is 'no'.
Likewise.
Show 11 quoted lines
> diff --git a/Documentation/fetch-options.txt b/Documentation/fetch-options.txt
> index a115a1ae0e..58972b1a05 100644
> --- a/Documentation/fetch-options.txt
> +++ b/Documentation/fetch-options.txt
> @@ -163,7 +163,8 @@ ifndef::git-pull[]
>  	value. Use 'on-demand' to only recurse into a populated submodule
>  	when the superproject retrieves a commit that updates the submodule's
>  	reference to a commit that isn't already in the local submodule
> -	clone.
> +	clone. By default this uses the fetch.recurseSubmodules value (see
> +	linkgit:git-config), and the default value is 'on-demand'.
	By default, 'on-demand' is used, unless
	`fetch.recurseSubmodules` is set (see linkgit:git-config[1]).
Previous: Damien RobertNext: Robert P. J. Day
Message 27 of 62 in “doc: --recurse-submodules”
  1. 0/4 doc: --recurse-submodulesDamien Robert, Feb 28, 2020
  2. 1/4 doc: list all commands affected by recurse.submoduleDamien Robert, Feb 28, 2020
  3. Philippe BlainMar 2, 2020
  4. Damien RobertMar 3, 2020
  5. 2/4 doc: document --recurse-submodules for reset and restoreDamien Robert, Feb 28, 2020
  6. Philippe BlainMar 2, 2020
  7. Damien RobertMar 3, 2020
  8. Philippe BlainMar 6, 2020
  9. 3/4 doc: explain how to deactivate recurse.submodule completelyDamien Robert, Feb 28, 2020
  10. Philippe BlainMar 2, 2020
  11. 4/4 doc: be more precise on (fetch|pull).recurseSubmodulesDamien Robert, Feb 28, 2020
  12. Philippe BlainMar 2, 2020
  13. Damien RobertFeb 28, 2020
  14. Philippe BlainMar 3, 2020
  15. Philippe BlainMar 2, 2020
  16. 0/5 doc: --recurse-submodulesDamien Robert, Mar 3, 2020
  17. 1/5 doc: list all commands affected by submodule.recurseDamien Robert, Mar 3, 2020
  18. 2/5 doc: document --recurse-submodules for reset and restoreDamien Robert, Mar 3, 2020
  19. Junio C HamanoMar 3, 2020
  20. Philippe BlainMar 6, 2020
  21. 3/5 doc: explain how to deactivate recurse.submodule completelyDamien Robert, Mar 3, 2020
  22. Junio C HamanoMar 3, 2020
  23. Robert P. J. DayMar 3, 2020
  24. Damien RobertMar 3, 2020
  25. Philippe BlainMar 6, 2020
  26. 4/5 doc: be more precise on (fetch|push).recurseSubmodulesDamien Robert, Mar 3, 2020
  27. Junio C HamanoMar 3, 2020
  28. Robert P. J. DayMar 3, 2020
  29. 5/5 doc: --recurse-submodules only apply to active submodulesDamien Robert, Mar 3, 2020
  30. Philippe BlainMar 6, 2020
  31. Damien RobertMar 20, 2020
  32. 0/5 doc: --recurse-submodulesDamien Robert, Mar 20, 2020
  33. 2/5 doc: document --recurse-submodules for reset and restoreDamien Robert, Mar 20, 2020
  34. Philippe BlainMar 22, 2020
  35. Damien RobertMar 25, 2020
  36. 3/5 doc: explain how to deactivate submodule.recurse completelyDamien Robert, Mar 20, 2020
  37. Philippe BlainMar 22, 2020
  38. 4/5 doc: be more precise on (fetch|push).recurseSubmodulesDamien Robert, Mar 20, 2020
  39. Philippe BlainMar 22, 2020
  40. Junio C HamanoMar 22, 2020
  41. Philippe BlainMar 22, 2020
  42. 5/5 doc: --recurse-submodules mostly only apply to active submodulesDamien Robert, Mar 20, 2020
  43. Philippe BlainMar 22, 2020
  44. 1/5 doc: list all commands affected by submodule.recurseDamien Robert, Mar 20, 2020
  45. 0/5 doc: --recurse-submodulesDamien Robert, Mar 25, 2020
  46. 1/5 doc: list all commands affected by submodule.recurseDamien Robert, Mar 25, 2020
  47. 2/5 doc: document --recurse-submodules for reset and restoreDamien Robert, Mar 25, 2020
  48. Philippe BlainMar 29, 2020
  49. 3/5 doc: explain how to deactivate submodule.recurse completelyDamien Robert, Mar 25, 2020
  50. 5/5 doc: --recurse-submodules mostly applies to active submodulesDamien Robert, Mar 25, 2020
  51. 4/5 doc: be more precise on (fetch|push).recurseSubmodulesDamien Robert, Mar 25, 2020
  52. Philippe BlainMar 29, 2020
  53. 0/5 doc: --recurse-submodulesDamien Robert, Apr 5, 2020
  54. 1/5 doc: list all commands affected by submodule.recurseDamien Robert, Apr 5, 2020
  55. 3/5 doc: explain how to deactivate submodule.recurse completelyDamien Robert, Apr 5, 2020
  56. 2/5 doc: document --recurse-submodules for reset and restoreDamien Robert, Apr 5, 2020
  57. 5/5 doc: --recurse-submodules mostly applies to active submodulesDamien Robert, Apr 5, 2020
  58. 4/5 doc: be more precise on (fetch|push).recurseSubmodulesDamien Robert, Apr 5, 2020
  59. Junio C HamanoApr 5, 2020
  60. Damien RobertApr 6, 2020
  61. Junio C HamanoApr 6, 2020
  62. Damien RobertApr 6, 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.