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

Re: [PATCH v3 4/5] clone: add a --no-tags-submodules to pass --no-tags to submodules

From
BWBrandon Williams <bmwill@google.com>
Date
Apr 27, 2017, 16:33 UTC
Message-ID
<20170427163314.GC80265@google.com>
In-Reply-To
<xmqqk266poih.fsf@gitster.mtv.corp.google.com>
On 04/26, Junio C Hamano wrote:
Show 21 quoted lines
> Ævar Arnfjörð Bjarmason  <avarab@gmail.com> writes:
> 
> > From: Brandon Williams <bmwill@google.com>
> >
> > Add a --no-tags-submodules which does for --no-tags what the existing
> > --shallow-submodules does for --depth, i.e. doing:
> >
> >     git clone --recurse-submodules --no-tags --no-tags-submodules <url>
> >
> > Will clone the superproject and all submodules with --no-tags
> > semantics.
> >
> > This change does not implement a submodule.*.tags config .gitmodules
> > configuration option corresponding to the existing submodule.*.shallow
> > facility, which would make --no-tags have full feature parity with
> > --shallow-submodules.
> 
> Shouldn't --no-tags automatically propagate down to submodules in
> --recurse-submodules mode instead?  I know --shallow-submodules
> exists but it looks to me more a misdesigned interface, rather than
> something we want to mimic in a new option.

I agree, I would think that the --no-tags option should be propagated down when --recurse-submodules is provided, without needed to provide another option for that. Thinking about the recursive case here (submodules in side of submodules) you would then need to propagate down two options, --no-tags and --no-tags-submodules, which feels a bit awkward.

Show 29 quoted lines
> The design of the traditional "git submodule" support strived to
> keep the superproject and its submodules distinct and separately
> managed as much as possible, and I view the motivation behind the
> recent push of "--recurse-submodules" as an attempt to make them
> appear as seamless as possible, so I have a feeling that a new
> option (like "--no-tags") that is applied to the superproject, as
> long as it also makes sense to use it in submodules, should
> propagate down in that mode by default (and most likely
> unconditionally).  Those who want finer granularity of control can
> use the traditional "work with superproject, and then initialize and
> update the submodules you are interested in in any way you want
> individually" mode anyway.
> 
> > Signed-off-by: Brandon Williams <bmwill@google.com>
> > Code-by: Brandon Williams <bmwill@google.com>
> > Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
> > Commit-message-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
> > Git-Completion-Code-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
> > Docs-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
> > Tests-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
> 
> Is it just me who finds this way of attribution unwieldy?  I would
> have expected to see something like this at the end
> 
> 	The main code is by Brandon, Ævar added the docs, tests and
> 	completion and wrapped them up into a commit with a log
> 	message.
> 
> before two s-o-b.

Yeah this looks a bit messy. Ævar, you've spent much longer on this topic than I have and should probably take authorship. I mean I only spent a little bit cobbling together a patch that I never tested. :) You're more than welcome to include my 'Signed-off-by' and/or a 'Helped-by' line for this patch though.

-- 
Brandon Williams
Previous: Junio C HamanoNext: Stefan Beller
Message 14 of 23 in “clone: --no-tags option”
  1. 0/5 clone: --no-tags optionÆvar Arnfjörð Bjarmason, Apr 26, 2017
  2. 1/5 tests: change "cd ... && git fetch" to "cd &&\n\tgit fetch"Ævar Arnfjörð Bjarmason, Apr 26, 2017
  3. 2/5 clone: add a --no-tags option to clone without tagsÆvar Arnfjörð Bjarmason, Apr 26, 2017
  4. Stefan BellerApr 27, 2017
  5. Brandon WilliamsApr 27, 2017
  6. Ævar Arnfjörð BjarmasonApr 28, 2017
  7. 3/5 tests: rename a test having to do with shallow submodulesÆvar Arnfjörð Bjarmason, Apr 26, 2017
  8. Stefan BellerApr 27, 2017
  9. Brandon WilliamsApr 27, 2017
  10. Ævar Arnfjörð BjarmasonApr 28, 2017
  11. Stefan BellerApr 28, 2017
  12. 4/5 clone: add a --no-tags-submodules to pass --no-tags to submodulesÆvar Arnfjörð Bjarmason, Apr 26, 2017
  13. Junio C HamanoApr 27, 2017
  14. Brandon WilliamsApr 27, 2017
  15. Stefan BellerApr 27, 2017
  16. Brandon WilliamsApr 27, 2017
  17. 5/5 WIP clone: add a --[no-]recommend-tags & submodule.NAME.tags configÆvar Arnfjörð Bjarmason, Apr 26, 2017
  18. Stefan BellerApr 27, 2017
  19. Brandon WilliamsApr 27, 2017
  20. Ævar Arnfjörð BjarmasonApr 28, 2017
  21. Ævar Arnfjörð BjarmasonApr 28, 2017
  22. Stefan BellerApr 28, 2017
  23. Junio C HamanoMay 1, 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.