Re: [PATCH] Teach git submodule update to use distributed repositories

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Thu, 17 Jul 2008, Nigel Magnay wrote:

> On Thu, Jul 17, 2008 at 1:13 PM, Johannes Schindelin
> <Johannes.Schindelin@xxxxxx> wrote:
>
> > On Thu, 17 Jul 2008, Nigel Magnay wrote:
> >
> >> When doing a git submodule update, it fetches any missing submodule 
> >> commits from the repository specified in .gitmodules.
> >
> > Huh?  It takes what is in .git/config!  Not what is in .gitmodules.
> 
> Huh? And where does .git/config get it from? Oh, that's right, 
> .gitmodules.

Oh, that's right, after "git submodule init".  Right before you are 
supposed to change them if your setup commands that.

> > So if you have another remote (or URL, e.g. if you have ssh:// access, 
> > but the .gitmodules file lists git://), just edit .git/config.
> 
> So for my usecase, you'd have me go in and change *evey single one* of 
> my submodule refs from the centralised repository, *every time* I want 
> to do a peer review?

No.

> Doesn't the current system strike you as being somewhat centralised in 
> nature?

No.

> > I meant, that is the whole _point_ of having a two-step init/update 
> > procedure.
> 
> Are you just determined that submodules should remain useless for "the 
> rest of us"?

No.

If you really need to change the "origin" back and forth between reviews, 
while the committed state of the superproject stays the same, then 
something is seriously awkward and needs to be streamlined in your setup.

Because when the superproject's revision stays the same, "git submodule 
update" may fetch additional objects if you specify another remote, but it 
will check out just the same revisions of the submodules.  Because they 
were committed as such.

But if you want to get objects from another server (as opposed to update 
the submodules' working directories to the latest committed revisions), 
which happens to have the identical layout of the principal server (which 
I would deem another setup peculiarity to be fixed), you might want to 
look into the recurse patch that was flying about on this list a few 
months back.

Hth,
Dscho

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux