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

Re: [PATCH] commit: configure submodules

From
Junio C Hamano <gitster@pobox.com>
Date
Sep 24, 2012, 05:57 UTC
Message-ID
<7vmx0g0xpm.fsf@alter.siamese.dyndns.org>
In-Reply-To
<505F5151.2080208@web.de>
Jens Lehmann <Jens.Lehmann@web.de> writes:
Show 7 quoted lines
>> Jens, what do you think?  I see no reason for anybody other than
>> "submodule init" to call gitmodules_config() that reads from the
>> in-tree .gitmodules file.
>
> I think the copying on init is not what we should do here because
> it sets the user's customization to what ever happened to be in
> .gitmodules at the time he initialized the submodule.

Hrm, why does the user have submodule.$name.$whatever customized before saying "submodule init $whategver" for that copying to be problematic?

> So I think Orgad's change is sane and should go in.

Matching what cmd_commit() does to what cmd_status() does, i.e. grab submodule.$name.ignore from somewhere, is not something I questioned. The patch is a good change to make them consistent.

What I was wondering was if that is a consistently wrong thing to do to read from .gitmodules not $GIT_DIR/config.

In any case, the log message I suggested in the review needs to be updated in the reroll to make it clear that this is about reading from .gitmodules, not "configuration". AFAICS, gitmodule_config() does not even read from $GIT_DIR/config, right?

Previous: Jens LehmannNext: Junio C Hamano
Message 4 of 14 in “commit: configure submodules”
  1. commit: configure submodulesOrgad Shaneh, Sep 23, 2012
  2. Junio C HamanoSep 23, 2012
  3. Jens LehmannSep 23, 2012
  4. Junio C HamanoSep 24, 2012
  5. Junio C HamanoSep 24, 2012
  6. Jens LehmannSep 24, 2012
  7. Junio C HamanoSep 24, 2012
  8. Orgad ShanehSep 24, 2012
  9. Junio C HamanoSep 24, 2012
  10. Orgad ShanehSep 24, 2012
  11. Jens LehmannSep 24, 2012
  12. Orgad ShanehSep 24, 2012
  13. Jens LehmannSep 24, 2012
  14. Junio C HamanoSep 24, 2012

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.