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

Re: [PATCH] unpack-trees.c: assume submodules are clean during check-out

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 5, 2007, 06:12 UTC
Message-ID
<7v4pjeh5lv.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<46B4A350.9060806@tromer.org>
Eran Tromer <git2eran@tromer.org> writes:
Show 5 quoted lines
> Another approach is for pull, checkout etc. to automatically update the
> submodule' head ref, but no more. In this case the supermodule always
> sees a consistent state with traditional semantics, but the *submodule*
> ends up with a dirty working tree and a head referring to a
> possibly-missing commit; "git submodule update" would need to clean that up.

That however would introduce the same problem as "pushing into live repository to update its HEAD while the index and working tree are looking the other way". We would need to somehow make it possible for the subdirectory to remember which commit the index and the working tree are derived from, so that the local changes can be merged back to the revision the submodule HEAD points at.

Previous: Eran TromerNext: Sven Verdoolaege
Message 9 of 16 in “unpack-trees.c: assume submodules are clean during check-out”
  1. unpack-trees.c: assume submodules are clean during check-outSven Verdoolaege, Jul 17, 2007
  2. Junio C HamanoJul 18, 2007
  3. Sven VerdoolaegeAug 1, 2007
  4. Junio C HamanoAug 4, 2007
  5. Lars HjemliAug 4, 2007
  6. Junio C HamanoAug 5, 2007
  7. Sven VerdoolaegeAug 5, 2007
  8. Eran TromerAug 4, 2007
  9. Junio C HamanoAug 5, 2007
  10. Sven VerdoolaegeAug 5, 2007
  11. Eran TromerAug 6, 2007
  12. Sven VerdoolaegeAug 6, 2007
  13. Eran TromerAug 7, 2007
  14. Sven VerdoolaegeAug 7, 2007
  15. Eran TromerAug 8, 2007
  16. Sven VerdoolaegeAug 8, 2007

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.