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

Re: [RFC 2/2] Don't push a repository with unpushed submodules

From
Fredrik Gustafsson <iveqy@iveqy.com>
Date
Jun 28, 2011, 21:59 UTC
Message-ID
<20110628215931.GA3974@paksenarrion.iveqy.com>
In-Reply-To
<7viprpu1p5.fsf@alter.siamese.dyndns.org>
On Tue, Jun 28, 2011 at 01:43:18PM -0700, Junio C Hamano wrote:
Show 10 quoted lines
> > This check is solely meant as a convenience security measure. It should
> > and can not enforce a tight check whether a superproject (including its
> > submodules) can be cloned/checked out at all times. But it ensures that
> > a developer has pushed his submodule commits "somewhere" which is enough
> > in practice.
> 
> I am not entirely convinced but if this would catch more than 80% of
> casual mistakes, it would be good enough.  I was hoping that somebody may
> come up with an idea that would work even in case (3), though.
> 

There's ways to do a "better" check, but only(*) if the client communicates with the server. This is expensive and doesn't make any sense to do for the error we're trying to prevent here, forgetful developers that forgotten to push a submodule.

A design goal for this check has been to make it just a client side check.

I do not have a % value of how usual this fault is. I do know that developers being introduced to submodules that I know of tends to forget this (and so do I occasionally).

* According to what I found out. If there's a better solution I would of
  course be very happy.
-- 
Med vänliga hälsningar
Fredrik Gustafsson

tel: 0733-608274
e-post: iveqy@iveqy.com
Previous: Junio C HamanoNext: Jens Lehmann
Message 7 of 14 in “[RFC 0/2] push checks for unpushed remotes in submodules”
  1. Fredrik GustafssonJun 26, 2011
  2. 1/2 test whether push checks for unpushed remotes in submodulesFredrik Gustafsson, Jun 26, 2011
  3. 2/2 Don't push a repository with unpushed submodulesFredrik Gustafsson, Jun 26, 2011
  4. Junio C HamanoJun 28, 2011
  5. Heiko VoigtJun 28, 2011
  6. Junio C HamanoJun 28, 2011
  7. Fredrik GustafssonJun 28, 2011
  8. Jens LehmannJun 28, 2011
  9. Heiko VoigtJul 4, 2011
  10. Marc BranchaudJun 28, 2011
  11. Jens LehmannJun 28, 2011
  12. Marc BranchaudJun 29, 2011
  13. Fredrik GustafssonJun 28, 2011
  14. Marc BranchaudJun 29, 2011

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.