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

Re: [PATCH] submodule: allow gitsubmodules to be pointed at tags

From
Sean Allred <allred.sean@gmail.com>
Date
Jun 24, 2024, 13:26 UTC
Message-ID
<m0wmmepj3b.fsf@epic96565.epic.com>
In-Reply-To
<pull.1703.git.git.1718625706679.gitgitgadget@gmail.com>

@dark0dave: sorry for the duplicate message; mu4e changed its default keybindings recently and I neglected to reply to the list as well...

"dark0dave via GitGitGadget" <gitgitgadget@gmail.com> writes:
Show 13 quoted lines
> Intent: Enable git submodules to point at tags,
> effectively freezing them
>
> Context: There is a large repo with 50+ submodules, the goal is
> to have some submodules update to HEAD but others to remain fixed.
> The update command does this by recursing through
> directories. This is very useful, however if an update is run,
> all the submodules are updated to HEAD.
>
> The goals:
> - Be able to create a submodule from a fixed tag (complete)
> - Be able to run git submodule update, with a flag to either update
> or keep the submodule pointed at the supplied tag (complete)

This is an interesting idea, so far as I understand it. I certainly appreciate the desire to freeze your dependencies. I don't use submodules often, but I do want to point out an inherent assumption in your design: that tags don't move.

Tags can move. It's usually impolite, but there can be reasonable use-cases for doing so.

With this in mind, what can go wrong if you have a submodule with a configuration that doesn't necessarily match the tree?

-- 
Sean Allred
Previous: dark0dave via GitGitGadgetNext: Sean Allred
Message 2 of 4 in “submodule: allow gitsubmodules to be pointed at tags”
  1. submodule: allow gitsubmodules to be pointed at tagsdark0dave via GitGitGadget, Jun 17, 2024
  2. Sean AllredJun 24, 2024
  3. Sean AllredJun 24, 2024
  4. Junio C HamanoJun 24, 2024

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.