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

Re: organizing multiple repositories with dependencies

From
HWHilco Wijbenga <hilco.wijbenga@gmail.com>
Date
Apr 24, 2012, 18:54 UTC
Message-ID
<CAE1pOi2KgeLPg7UVRP7dbqLFJErsKUx22Mi5aSkphy7KMJhoUQ@mail.gmail.com>
In-Reply-To
<nnghaw93v8n.fsf@transit.us.cray.com>
On 24 April 2012 10:17,  <dag@cray.com> wrote:
Show 9 quoted lines
> Hilco Wijbenga <hilco.wijbenga@gmail.com> writes:
>
>> I'm assuming that if you have subproject S in umbrella project U and a
>> branch "topic" in U then that same branch should exist in S.
>
> No, I think that is actually very rare.  If topic branches really should
> be mirrored then U and S should be one repository.  They are too closely
> coupled to be separated.  But see the but about git-subtree and topic
> branches below.

Too closely coupled? I do not think breaking up a project into a set of libraries makes everything tightly coupled. I would argue the opposite. :-) Anyway, you answer my concern below.

Show 20 quoted lines
>>> Of course, this is entirely driven by git-subtree's model of actually
>>> incorporating subproject history into one big umbrella repository.
>>> There is no separation between the subprojects and umbrella projects.
>>> It's one giant history.  Therefore, push/pull to/from subprojects are
>>> explicit operations.  That's probably not the best model for every
>>> situation but I find it very nice.
>>
>> I do not have enough (okay, any) experience with subtree to comment on
>> that. The first part seems just what I want. I'm not sure about the
>> explicit pushing/pulling part. That sounds too much like asking for
>> the sort of problems that scared us away from submodules. Hopefully,
>> I'm dead wrong. :-)
>
> With subtrees, a topic branch in the umbrella project WILL be reflected
> in the subproject because it is really one big repository.  It's a
> little inconvenient to subtree push a new tag at the moment.  You have
> to do a subtree split to a new branch and then push the branch to the
> original component repository.  That's one thing I want to improve in
> the short term.  I have found a need for then when creating release
> tags.

Okay, that would work fine. I have no problem with a bit of extra work here. (In fact, this is probably where I would *want* a bit of extra control.)

What would happen if you had a bunch of commits in the umbrella project and then did a push? Would that error out? Are there protections in place to prevent developers from making silly mistakes like that?

Show 6 quoted lines
> But still, it seems odd to me that you'd create a topic branch in U and
> then want to push it to a separate S repository.  Topic branches are by
> nature ephemeral and I have never had a need to do something like that.
> It just seems to go against the grain of what a topic branch is.  As I
> said above, release tags and such are in a different category and that
> is the main target of the subtree push enhancements I want to make.

I had not realized all changes would simply be part of the umbrella project. Given that, a topic branch in each subproject's repo is unnecessary.

Cheers, Hilco

Previous: dag@cray.comNext: PJ Weisberg
Message 15 of 34 in “organizing multiple repositories with dependencies”
  1. Namit BhallaApr 16, 2012
  2. Jakub NarebskiApr 16, 2012
  3. dag@cray.comApr 16, 2012
  4. Hilco WijbengaApr 17, 2012
  5. dag@cray.comApr 17, 2012
  6. Seth RobertsonApr 17, 2012
  7. Hilco WijbengaApr 17, 2012
  8. dag@cray.comApr 17, 2012
  9. Hilco WijbengaApr 17, 2012
  10. PJ WeisbergApr 17, 2012
  11. Hilco WijbengaApr 17, 2012
  12. Namit BhallaApr 18, 2012
  13. Jens LehmannApr 18, 2012
  14. dag@cray.comApr 24, 2012
  15. Hilco WijbengaApr 24, 2012
  16. PJ WeisbergApr 24, 2012
  17. Hilco WijbengaApr 24, 2012
  18. dag@cray.comApr 24, 2012
  19. Phil HordApr 30, 2012
  20. dag@cray.comApr 30, 2012
  21. Jens LehmannApr 18, 2012
  22. dag@cray.comApr 24, 2012
  23. Seth RobertsonApr 24, 2012
  24. Jens LehmannApr 24, 2012
  25. Seth RobertsonApr 24, 2012
  26. dag@cray.comApr 24, 2012
  27. username localhostApr 28, 2012
  28. dag@cray.comApr 24, 2012
  29. Seth RobertsonApr 25, 2012
  30. dag@cray.comApr 27, 2012
  31. Eugene SajineApr 24, 2012
  32. Hilco WijbengaApr 24, 2012
  33. dag@cray.comApr 24, 2012
  34. dag@cray.comApr 24, 2012

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.