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

Re: [PATCH] submodule add: always initialize .git/config entry

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 30, 2011, 00:47 UTC
Message-ID
<7vwrg4qh61.fsf@alter.siamese.dyndns.org>
In-Reply-To
<4E066E8A.7060209@web.de>
Jens Lehmann <Jens.Lehmann@web.de> writes:
Show 21 quoted lines
> Am 24.06.2011 06:13, schrieb Junio C Hamano:
>> Shouldn't "submodule add" add an entry for .git/config even when it cloned
>> from elsewhere?
>
> Yes, we should be consistent here.
>
>> I suspect this fix will cascade to breakage elsewhere, but I've run out of
>> energy and inclination to look at the submodule code tonight, so I'll let
>> the list to take it further from here.
>
> Ok, t7406 expected "git submodule init" to copy the new update setting
> into .git/config for a newly added submodule, which it didn't do anymore
> because it already found the url set. I solved that by teaching init to
> only then copy the url and update settings if they aren't present yet.
> Now all tests are running fine and your change to the test I added in
> jl/submodule-add-relurl-wo-upstream isn't necessary anymore.
>
> When I cherry pick that onto cbd0a3c6bc in your current pu branch and
> resolve the conflicts all tests run fine (if you want me to resend this
> patch based on that commit to avoid the conflicts with i18n and the
> "submodule add: clean up duplicated code" patch please just say so).
Hmm, now 7610 seems to expect somewhat different behaviour and fails.
Previous: Jens LehmannNext: Jens Lehmann
Message 11 of 15 in “''git submodule sync'' should not add uninitialized submodules to .git/config”
  1. Maarten BillemontJun 23, 2011
  2. Phil HordJun 23, 2011
  3. Junio C HamanoJun 23, 2011
  4. Jens LehmannJun 23, 2011
  5. Junio C HamanoJun 23, 2011
  6. Andreas KöhlerJun 23, 2011
  7. Jens LehmannJun 24, 2011
  8. Re* ''git submodule sync'' should not add uninitialized submodules to .git/configJunio C Hamano, Jun 24, 2011
  9. Jens LehmannJun 24, 2011
  10. submodule add: always initialize .git/config entryJens Lehmann, Jun 25, 2011
  11. Junio C HamanoJun 30, 2011
  12. submodule sync: do not auto-vivify uninteresting submoduleJens Lehmann, Jun 25, 2011
  13. Phil HordJun 23, 2011
  14. Junio C HamanoJun 23, 2011
  15. Phil HordJun 23, 2011

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.