{"thread":{"id":"50936","subject":"[PATCH] git-submodule.txt: mention that 'git submodule update' fetches missing commits","startedAt":"2019-04-15T19:24:04Z","lastAt":"2019-11-24T06:05:23Z","messageCount":7,"participants":["Philippe Blain","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"373893","messageId":"0102016a2274c90f-3dbf792f-5b0a-4da4-ada0-9a163a14e68d-000000@eu-west-1.amazonses.com","threadId":"50936","inReplyTo":null,"subject":"[PATCH] git-submodule.txt: mention that 'git submodule update' fetches missing commits","fromName":"Philippe Blain","fromEmail":"philippe.blain@canada.ca","sentAt":"2019-04-15T19:24:00Z","receivedAt":"2019-04-15T19:24:04Z","isPatch":true,"sender":{"key":"philippe.blain@canada.ca","avatar":null},"body":"'git submodule update' will fetch new commits from the submodule remote\nif the SHA-1 recorded in the superproject is not found. This was not\nmentioned in the documentation.\n---\n Documentation/git-submodule.txt | 3 ++-\n 1 file changed, 2 insertions(+), 1 deletion(-)\n\ndiff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt\nindex ba3c4df550acf..026ee07a2b641 100644\n--- a/Documentation/git-submodule.txt\n+++ b/Documentation/git-submodule.txt\n@@ -128,7 +128,8 @@ update [--init] [--remote] [-N|--no-fetch] [--[no-]recommend-shallow] [-f|--forc\n +\n --\n Update the registered submodules to match what the superproject\n-expects by cloning missing submodules and updating the working tree of\n+expects by cloning missing submodules, fetching missing submodule commits\n+and updating the working tree of\n the submodules. The \"updating\" can be done in several ways depending\n on command line options and the value of `submodule.<name>.update`\n configuration variable. The command line option takes precedence over\n\n--\nhttps://github.com/git/git/pull/596\n"},{"id":"377604","messageId":"0102016b72a55a7d-fb4ecdb7-9f2b-4204-b888-0000f209c3ff-000000@eu-west-1.amazonses.com","threadId":"50936","inReplyTo":"0102016a2274c90f-3dbf792f-5b0a-4da4-ada0-9a163a14e68d-000000@eu-west-1.amazonses.com","subject":"[PATCH] doc: mention that 'git submodule update' fetches missing commits","fromName":"Philippe Blain","fromEmail":"levraiphilippeblain@gmail.com","sentAt":"2019-06-20T02:09:27Z","receivedAt":"2019-06-20T02:09:30Z","isPatch":true,"sender":{"key":"levraiphilippeblain@gmail.com","avatar":"https://avatars.githubusercontent.com/u/44212482?v=4"},"body":"'git submodule update' will fetch new commits from the submodule remote\nif the SHA-1 recorded in the superproject is not found. This was not\nmentioned in the documentation.\n\nSigned-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\n---\n Documentation/git-submodule.txt | 3 ++-\n 1 file changed, 2 insertions(+), 1 deletion(-)\n\ndiff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt\nindex 2794e2978021c..930bfcee50e4c 100644\n--- a/Documentation/git-submodule.txt\n+++ b/Documentation/git-submodule.txt\n@@ -132,7 +132,8 @@ update [--init] [--remote] [-N|--no-fetch] [--[no-]recommend-shallow] [-f|--forc\n +\n --\n Update the registered submodules to match what the superproject\n-expects by cloning missing submodules and updating the working tree of\n+expects by cloning missing submodules, fetching missing submodule commits\n+and updating the working tree of\n the submodules. The \"updating\" can be done in several ways depending\n on command line options and the value of `submodule.<name>.update`\n configuration variable. The command line option takes precedence over\n\n--\nhttps://github.com/git/git/pull/596\n"},{"id":"377683","messageId":"xmqqsgs4nn6k.fsf@gitster-ct.c.googlers.com","threadId":"50936","inReplyTo":"0102016b72a55a7d-fb4ecdb7-9f2b-4204-b888-0000f209c3ff-000000@eu-west-1.amazonses.com","subject":"Re: [PATCH] doc: mention that 'git submodule update' fetches missing commits","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2019-06-20T18:09:39Z","receivedAt":"2019-06-20T18:23:12Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Philippe Blain <levraiphilippeblain@gmail.com> writes:\n\n> 'git submodule update' will fetch new commits from the submodule remote\n> if the SHA-1 recorded in the superproject is not found. This was not\n> mentioned in the documentation.\n>\n> Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\n> ---\n>  Documentation/git-submodule.txt | 3 ++-\n>  1 file changed, 2 insertions(+), 1 deletion(-)\n>\n> diff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt\n> index 2794e2978021c..930bfcee50e4c 100644\n> --- a/Documentation/git-submodule.txt\n> +++ b/Documentation/git-submodule.txt\n> @@ -132,7 +132,8 @@ update [--init] [--remote] [-N|--no-fetch] [--[no-]recommend-shallow] [-f|--forc\n>  +\n>  --\n>  Update the registered submodules to match what the superproject\n> -expects by cloning missing submodules and updating the working tree of\n> +expects by cloning missing submodules, fetching missing submodule commits\n> +and updating the working tree of\n>  the submodules. The \"updating\" can be done in several ways depending\n>  on command line options and the value of `submodule.<name>.update`\n>  configuration variable. The command line option takes precedence over\n\nThe additional text may not be wrong per-se, but isn't it fairly\nobvious that there is no other way than to fetch, in order to\n\"update the registered submodules to match what the superproject\nexpects\", aka \"if the commit object name recorded in the\nsuperproject is not found\".  How else would the subcommand come up\nwith the missing commit out of thin air?\n\nIOW, I have to wonder if this is worth saying, or if these new words\nare just adding more things the readers need to scan on the page\nwithout adding that much information.\n"},{"id":"386504","messageId":"9B605234-8F49-4FEB-9156-22367E01B08B@gmail.com","threadId":"50936","inReplyTo":"xmqqsgs4nn6k.fsf@gitster-ct.c.googlers.com","subject":"Re: [PATCH] doc: mention that 'git submodule update' fetches missing commits","fromName":"Philippe Blain","fromEmail":"levraiphilippeblain@gmail.com","sentAt":"2019-11-19T03:55:37Z","receivedAt":"2019-11-19T03:55:41Z","isPatch":true,"sender":{"key":"levraiphilippeblain@gmail.com","avatar":"https://avatars.githubusercontent.com/u/44212482?v=4"},"body":"Hi Junio,\n\nFirst off, sorry for not answering this summer. \nDscho suggested [1] I try to convince you. \n\n> Le 20 juin 2019 à 14:09, Junio C Hamano <gitster@pobox.com> a écrit :\n> \n> The additional text may not be wrong per-se, but isn't it fairly\n> obvious that there is no other way than to fetch, in order to\n> \"update the registered submodules to match what the superproject\n> expects »,\n\nWell, that’s true, but I think that it is important in the documentation to be thorough as to what git commands talk to a remote in what circumstances, and which don’t (this is something that is sometimes not obvious to new users in my opinion). Since by default ‘git pull’ will fetch missing submodule commits, it may not be obvious that ‘git submodule update’ will also fetch from a remote if need be. \n\n> How else would the subcommand come up\n> with the missing commit out of thin air?\n\nSince 'git pull’ will fetch submodules changes, and is usually run first, the commits are usually already there, but I think it’s worth mentioning that they will be fetched if they need to.\n\nI like thoroughness in software documentation :) \n\nPhilippe.\n\n[1] https://github.com/git/git/pull/596"},{"id":"386601","messageId":"xmqq8sobdzul.fsf@gitster-ct.c.googlers.com","threadId":"50936","inReplyTo":"9B605234-8F49-4FEB-9156-22367E01B08B@gmail.com","subject":"Re: [PATCH] doc: mention that 'git submodule update' fetches missing commits","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2019-11-20T02:51:46Z","receivedAt":"2019-11-20T02:51:52Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Philippe Blain <levraiphilippeblain@gmail.com> writes:\n\n> Since 'git pull’ will fetch submodules changes, and is usually\n> run first, the commits are usually already there, but I think\n> it’s worth mentioning that they will be fetched if they need to.\n>\n> I like thoroughness in software documentation :) \n\nWhere to draw the line between being thorough and being overly\nverbose with trivial things is subjective, so I generally tend to\nside with status quo.  But after re-reading the updated text, I do\nnot think it is so bad, so let's apply it with a bit of tweak.\n\nThe lines prefixed with \"++\" are with my tweak, \"- \" are your\noriginal changes and \" -\" are what was in the version before your\npatch (I CC'ed Pratyush to show this as an example of what I meant\nby using combined diff to express an amended commit):\n\n$ git diff -c HEAD HEAD@{1} HEAD^\ndiff --combined Documentation/git-submodule.txt\nindex 16c765cbfa,0ed5c24dc1..4beb569ae5\n--- a/Documentation/git-submodule.txt\n+++ b/Documentation/git-submodule.txt\n@@@ -133,8 -133,7 +133,8 @@@ update [--init] [--remote] [-N|--no-fet\n  +\n  --\n  Update the registered submodules to match what the superproject\n- expects by cloning missing submodules, fetching missing submodule commits\n- and updating the working tree of\n -expects by cloning missing submodules and updating the working tree of\n++expects by cloning missing submodules, fetching missing commits\n++in submodules and updating the working tree of\n  the submodules. The \"updating\" can be done in several ways depending\n  on command line options and the value of `submodule.<name>.update`\n  configuration variable. The command line option takes precedence over\n"},{"id":"386926","messageId":"1574560895-60251-1-git-send-email-levraiphilippeblain@gmail.com","threadId":"50936","inReplyTo":"0102016a2274c90f-3dbf792f-5b0a-4da4-ada0-9a163a14e68d-000000@eu-west-1.amazonses.com","subject":"[PATCH v2] doc: mention that 'git submodule update' fetches missing commits","fromName":"Philippe Blain","fromEmail":"levraiphilippeblain@gmail.com","sentAt":"2019-11-24T02:01:35Z","receivedAt":"2019-11-24T02:02:00Z","isPatch":true,"sender":{"key":"levraiphilippeblain@gmail.com","avatar":"https://avatars.githubusercontent.com/u/44212482?v=4"},"body":"'git submodule update' will fetch new commits from the submodule remote\nif the SHA-1 recorded in the superproject is not found. This was not\nmentioned in the documentation.\n\nHelped-by: Junio C Hamano <gitster@pobox.com>\nHelped-by: Johannes Schindelin <johannes.schindelin@gmx.de>\nSigned-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\nSigned-off-by: Junio C Hamano <gitster@pobox.com>\n---\nChanges since v1 [4]:\n- Added my signed-off, corrected my email address\n  and shortened the title of the commit message\n  (I had actually done that when I resent my patch in [1] using submitGit, \n  but this dit not add the \"v2\" prefix)\n- Added Junio's suggestion [2] (which was applied in [3] on top of the original \n  submission [4] instead of the revised one [1]), and squashed\n- Added Helped-by trailers\n- Rebased on v2.23.0 (as was done for [3])\n\n[1] https://public-inbox.org/git/0102016b72a55a7d-fb4ecdb7-9f2b-4204-b888-0000f209c3ff-000000@eu-west-1.amazonses.com/\n[2] https://public-inbox.org/git/xmqq8sobdzul.fsf@gitster-ct.c.googlers.com/\n[3] https://github.com/gitster/git/commits/pb/submodule-update-fetches\n[4] https://public-inbox.org/git/0102016a2274c90f-3dbf792f-5b0a-4da4-ada0-9a163a14e68d-000000@eu-west-1.amazonses.com/\n\n Documentation/git-submodule.txt | 3 ++-\n 1 file changed, 2 insertions(+), 1 deletion(-)\n\ndiff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt\nindex 0ed5c24dc1..4beb569ae5 100644\n--- a/Documentation/git-submodule.txt\n+++ b/Documentation/git-submodule.txt\n@@ -133,7 +133,8 @@ update [--init] [--remote] [-N|--no-fetch] [--[no-]recommend-shallow] [-f|--forc\n +\n --\n Update the registered submodules to match what the superproject\n-expects by cloning missing submodules and updating the working tree of\n+expects by cloning missing submodules, fetching missing commits\n+in submodules and updating the working tree of\n the submodules. The \"updating\" can be done in several ways depending\n on command line options and the value of `submodule.<name>.update`\n configuration variable. The command line option takes precedence over\n-- \n2.23.0\n\n"},{"id":"386932","messageId":"xmqqsgmdzu5e.fsf@gitster-ct.c.googlers.com","threadId":"50936","inReplyTo":"1574560895-60251-1-git-send-email-levraiphilippeblain@gmail.com","subject":"Re: [PATCH v2] doc: mention that 'git submodule update' fetches missing commits","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2019-11-24T06:05:17Z","receivedAt":"2019-11-24T06:05:23Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Philippe Blain <levraiphilippeblain@gmail.com> writes:\n\n> 'git submodule update' will fetch new commits from the submodule remote\n> if the SHA-1 recorded in the superproject is not found. This was not\n> mentioned in the documentation.\n>\n> Helped-by: Junio C Hamano <gitster@pobox.com>\n> Helped-by: Johannes Schindelin <johannes.schindelin@gmx.de>\n> Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\n> Signed-off-by: Junio C Hamano <gitster@pobox.com>\n> ---\n> Changes since v1 [4]:\n> - Added my signed-off, corrected my email address\n>   and shortened the title of the commit message\n>   (I had actually done that when I resent my patch in [1] using submitGit, \n>   but this dit not add the \"v2\" prefix)\n> - Added Junio's suggestion [2] (which was applied in [3] on top of the original \n>   submission [4] instead of the revised one [1]), and squashed\n> - Added Helped-by trailers\n> - Rebased on v2.23.0 (as was done for [3])\n\nThanks, will replace.  This should be ready for 'next', I would\nthink.\n"}]}