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

[RFC/WIP PATCH 0/3] fetch moved submodules on-demand

From
Heiko Voigt <hvoigt@hvoigt.net>
Date
Feb 25, 2013, 01:02 UTC
Message-ID
<cover.1361751905.git.hvoigt@hvoigt.net>
Hi,

this is a series I have been working on and off. My plan is that it might be part of a slightly bigger series also implementing on-demand clone of submodules into the .git/modules folder if a submodule is configured like that.

This is needed as preparation for the final goal of automatic checkout/deletion of submodules when they appear/disappear. My plan is to introduce a new .gitmodules variable

	submodule.<name>.init

to specify whether a submodule should be initialized (and thus cloned) by default or not. If not configured it will default to off to stay closed to the current behavior. If it proves useful we can maybe change that default later to on.

That way we would get much closer to "clone/fetch and get everything you need to work on a project".

I send this series mainly to inform people what I have been working and to maybe get some early feedback about the approach. Let me know what you think.

Cheers Heiko
Heiko Voigt (3):
  teach config parsing to read from strbuf
  implement fetching of moved submodules
  submodule: simplify decision tree whether to or not to fetch
 .gitignore                  |   1 +
 Makefile                    |   2 +
 cache.h                     |   1 +
 config.c                    | 119 +++++++++++++++++-----
 submodule-config-cache.c    |  96 ++++++++++++++++++
 submodule-config-cache.h    |  34 +++++++
 submodule.c                 | 242 ++++++++++++++++++++++++++++++++++++--------
 t/t1300-repo-config.sh      |   4 +
 t/t5526-fetch-submodules.sh |  31 ++++++
 test-config.c               |  41 ++++++++
 10 files changed, 502 insertions(+), 69 deletions(-)
 create mode 100644 submodule-config-cache.c
 create mode 100644 submodule-config-cache.h
 create mode 100644 test-config.c
-- 
1.8.2.rc0.25.g5062c01
Next: Heiko Voigt
Message 1 of 25 in “fetch moved submodules on-demand”
  1. 0/3 fetch moved submodules on-demandHeiko Voigt, Feb 25, 2013
  2. 1/3 teach config parsing to read from strbufHeiko Voigt, Feb 25, 2013
  3. Junio C HamanoFeb 25, 2013
  4. Heiko VoigtFeb 25, 2013
  5. 0/4 allow more sources for config valuesHeiko Voigt, Feb 26, 2013
  6. 1/4 config: factor out config file stack managementHeiko Voigt, Feb 26, 2013
  7. Jeff KingFeb 26, 2013
  8. Heiko VoigtFeb 26, 2013
  9. Jeff KingFeb 26, 2013
  10. Junio C HamanoFeb 26, 2013
  11. Heiko VoigtFeb 27, 2013
  12. Junio C HamanoFeb 26, 2013
  13. Heiko VoigtFeb 27, 2013
  14. 2/4 config: drop file pointer validity check in get_next_char()Heiko Voigt, Feb 26, 2013
  15. Jeff KingFeb 26, 2013
  16. Heiko VoigtFeb 27, 2013
  17. Heiko VoigtFeb 28, 2013
  18. Heiko VoigtFeb 28, 2013
  19. 3/4 config: make parsing stack struct independent from actual data sourceHeiko Voigt, Feb 26, 2013
  20. 4/4 teach config parsing to read from strbufHeiko Voigt, Feb 26, 2013
  21. Ramsay JonesMar 7, 2013
  22. Heiko VoigtMar 10, 2013
  23. Jeff KingFeb 26, 2013
  24. 2/3 implement fetching of moved submodulesHeiko Voigt, Feb 25, 2013
  25. 3/3 submodule: simplify decision tree whether to or not to fetchHeiko Voigt, Feb 25, 2013

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.