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

Re: Feature Request: Branch-Aware Submodules

From
Jacob Keller <jacob.keller@gmail.com>
Date
Aug 29, 2016, 02:17 UTC
Message-ID
<CA+P7+xqA_3a8EPZ=2Y5pgkL+N=_F1v5pfyzErwest9aoKZC37w@mail.gmail.com>
In-Reply-To
<51671371-C59A-4304-99B2-B2C2256C4001@student.ethz.ch>

On Fri, Aug 26, 2016 at 8:12 AM, Hedges Alexander <ahedges@student.ethz.ch> wrote:

Show 12 quoted lines
>> On 25 Aug 2016, at 19:45, Stefan Beller <sbeller@google.com> wrote:
>> [1] https://github.com/jlehmann/git-submod-enhancements
>> which has some attempts for checkout including the submodules.
>> I also tried writing some patches which integrate checking out submodules
>> via checkout as well. A quicker `solution` would be a config option that
>> just runs `git submodule update` after each checkout/pull etc.
>>
>
> I see. The quick fix is almost what I’m looking for, except that it leaves
> the repo in a detached head state. Could the submodule update be made
> automatically and intelligently pick the branch?
>

You probably want "git submodule update --rebase" or "git submodule update --merge" See git help submodule under the update section, or even a custom command variant where you can write your own bit of shell that does what your project expects.

Thanks, Jake

Previous: Hedges AlexanderNext: Hedges Alexander
Message 2 of 3 in “Re: Feature Request: Branch-Aware Submodules”
  1. Hedges AlexanderAug 26, 2016
  2. Jacob KellerAug 29, 2016
  3. Hedges AlexanderSep 1, 2016

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.