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

Re: [PATCH] submodule: Fix documentation of update subcommand

From
Jens Lehmann <jens.lehmann@web.de>
Date
Nov 3, 2014, 20:58 UTC
Message-ID
<5457EC81.2060504@web.de>
In-Reply-To
<xmqqsii0qa4l.fsf@gitster.dls.corp.google.com>
Am 03.11.2014 um 21:53 schrieb Junio C Hamano:
Show 42 quoted lines
> I did a bit more digging of the history, and came up with this,
> which would be with a clearer and fairer description.  Also to
> clarify, I spelled what Michal's "This" meant to refer to.
>
> -- >8 --
> From: Michal Sojka <sojkam1@fel.cvut.cz>
> Date: Mon, 3 Nov 2014 11:09:51 +0100
> Subject: [PATCH] submodule: clarify documentation for update subcommand
>
> e6a1c43a (document submdule.$name.update=none option for gitmodules,
> 2012-05-10) meant to say "Unlike the case where your .update
> configuration is set to either 'rebase' or 'merge', when it is set
> to 'none', the tip of the submodule would never move.  You can use
> the --checkout option if you want the contents of the submodule to
> be updated to some other commit."
>
> But the resulting text made it sound as if using "--checkout" would
> have no effect when .update configuration is set to 'rebase' or
> 'merge', which was misleading.  In fact, with the "--checkout"
> option, the tip of the submodule moves to the exact commit that is
> recorded in the superproject tree, regardless of .update
> configuration.
>
> Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
> Signed-off-by: Junio C Hamano <gitster@pobox.com>
> ---
>   Documentation/git-submodule.txt | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt
> index 8e6af65..648323f 100644
> --- a/Documentation/git-submodule.txt
> +++ b/Documentation/git-submodule.txt
> @@ -158,7 +158,7 @@ update::
>   	checkout the commit specified in the index of the containing repository.
>   	This will make the submodules HEAD be detached unless `--rebase` or
>   	`--merge` is specified or the key `submodule.$name.update` is set to
> -	`rebase`, `merge` or `none`. `none` can be overridden by specifying
> +	`rebase`, `merge` or `none`. The configuration can be overridden by specifying
>   	`--checkout`. Setting the key `submodule.$name.update` to `!command`
>   	will cause `command` to be run. `command` can be any arbitrary shell
>   	command that takes a single argument, namely the sha1 to update to.
Yup, but we should also mention '--merge' and '--rebase' here.
Previous: Junio C HamanoNext: Junio C Hamano
Message 10 of 25 in “submodule: Fix documentation of update subcommand”
  1. submodule: Fix documentation of update subcommandMichal Sojka, Nov 3, 2014
  2. Junio C HamanoNov 3, 2014
  3. Jens LehmannNov 3, 2014
  4. Junio C HamanoNov 3, 2014
  5. Michal SojkaNov 3, 2014
  6. Junio C HamanoNov 3, 2014
  7. Jens LehmannNov 4, 2014
  8. Junio C HamanoNov 4, 2014
  9. Junio C HamanoNov 3, 2014
  10. Jens LehmannNov 3, 2014
  11. Junio C HamanoFeb 17, 2015
  12. submodule: Fix documentation of update subcommandMichal Sojka, Feb 18, 2015
  13. Junio C HamanoFeb 18, 2015
  14. Michal SojkaFeb 19, 2015
  15. submodule: Improve documentation of update subcommandMichal Sojka, Feb 19, 2015
  16. Junio C HamanoFeb 20, 2015
  17. Michal SojkaFeb 23, 2015
  18. submodule: Improve documentation of update subcommandMichal Sojka, Feb 23, 2015
  19. Junio C HamanoFeb 23, 2015
  20. Junio C HamanoFeb 23, 2015
  21. Michal SojkaMar 2, 2015
  22. submodule: Improve documentation of update subcommandMichal Sojka, Mar 2, 2015
  23. submodule: Improve documentation of update subcommandMichal Sojka, Mar 2, 2015
  24. Junio C HamanoMar 2, 2015
  25. Michal SojkaNov 3, 2014

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.