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

Re: Submodule regression in 2.14?

From
Stefan Beller <sbeller@google.com>
Date
Aug 18, 2017, 04:02 UTC
Message-ID
<CAGZ79kZdnJ+bATTxKBhsJnKaJWGqcBu3MOQ9eK7m4j3dJPNbTw@mail.gmail.com>
In-Reply-To
<xmqqd17tei7m.fsf@gitster.mtv.corp.google.com>
On Thu, Aug 17, 2017 at 7:13 PM, Junio C Hamano <gitster@pobox.com> wrote:
Show 11 quoted lines
> Stefan Beller <sbeller@google.com> writes:
>
>> Are you saying this might be a design mistake and
>> the .update ought to be respected by all the other
>> commands? For example
>>     git reset --recurse-submodules
>> should ignore the .update= none?
>
> I have been under the impression that that has been the traditional
> desire of what .update ought to mean.  I personally do not have a
> strong opinion---at least not yet.

In this context note v2.14.0-rc1-34-g7463e2ec3 (bw/submodule-config-cleanup~7, "unpack-trees: don't respect submodule.update") that is going opposite of your impression.

Show 8 quoted lines
>> When designing these new recursive submodule functionality
>> outside the "submodule" command, I'd want submodules
>> to behave as much as possible like trees.
>
> I think that is sensible as long as the user does not explicitly say
> "this and that submodule behave differently" by giving configuration
> variables.  Perhaps .update is one of those that should countermand
> the default behaviour of "--recurse-submodules"?

Maybe, I'll think about it. However there is no such equivalent for trees (and AFAICT never came up) to treat a specific directory other than the rest in worktree operations.

The problem with the issue in question is however: git-pull is a combination of two other high level commands (fetch/merge), the fetch component already had a recursive behavior, and that commit in question added a bit for the merge component, so the UX is hard to get right for both of them:

    git pull --recurse=fetch-only
    git pull --recurse=merge-respects-update-strategy
is what I'd want to avoid.

So maybe we can just respect the update strategy before starting the local part.

Stefan
Previous: Junio C HamanoNext: Junio C Hamano
Message 7 of 38 in “Submodule regression in 2.14?”
  1. Lars SchneiderAug 16, 2017
  2. Stefan BellerAug 16, 2017
  3. Stefan BellerAug 16, 2017
  4. Lars SchneiderAug 17, 2017
  5. Stefan BellerAug 17, 2017
  6. Junio C HamanoAug 18, 2017
  7. Stefan BellerAug 18, 2017
  8. Junio C HamanoAug 18, 2017
  9. Stefan BellerAug 18, 2017
  10. Junio C HamanoAug 19, 2017
  11. Heiko VoigtAug 21, 2017
  12. Stefan BellerAug 21, 2017
  13. Heiko VoigtAug 22, 2017
  14. Stefan BellerAug 22, 2017
  15. Heiko VoigtAug 25, 2017
  16. Stefan BellerAug 25, 2017
  17. Junio C HamanoAug 25, 2017
  18. Junio C HamanoAug 21, 2017
  19. Heiko VoigtAug 22, 2017
  20. Stefan BellerAug 21, 2017
  21. Junio C HamanoAug 21, 2017
  22. Lars SchneiderAug 18, 2017
  23. Stefan BellerAug 18, 2017
  24. Junio C HamanoAug 18, 2017
  25. pull: respect submodule update configurationStefan Beller, Aug 18, 2017
  26. Stefan BellerAug 18, 2017
  27. Junio C HamanoAug 19, 2017
  28. Junio C HamanoAug 19, 2017
  29. Heiko VoigtAug 21, 2017
  30. Stefan BellerAug 21, 2017
  31. Lars SchneiderAug 21, 2017
  32. Stefan BellerAug 21, 2017
  33. Brandon WilliamsAug 21, 2017
  34. Junio C HamanoAug 21, 2017
  35. Lars SchneiderAug 22, 2017
  36. Stefan BellerAug 22, 2017
  37. Brandon WilliamsAug 22, 2017
  38. Lars SchneiderAug 19, 2017

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.