Thread (2 messages) flat view 2 messages, 2 authors, 2016-08-05

Re: [PATCH 0/6] git clone: Marry --recursive and --reference

From: Stefan Beller <hidden>
Date: 2016-08-05 21:24:14

On Fri, Aug 5, 2016 at 12:47 PM, Junio C Hamano [off-list ref] wrote:
 * You want the "clone" command above with "--recursive" to do "the
   right thing".  That is, the clone of the superproject borrows
   from /var/cache/super.git local mirror, and the clone of xyzzy
   that would be made at .git/modules/xyzzy in the superproject
   would borrow from /var/cache/xyzzy.git local mirror.
This is not what I intend to solve here. The solution in 6/6 solves
the scenario as you outlined in [1].
What I am not sure about is how /var/cache/xyzzy.git should be
automatically derived from the information given from the command
line of "clone" and what the clone of the superproject contains.
Generally speaking you cannot do that without assumptions.

The scenario in [1] can be done without assumptions of the locations
of the submodules. The only requirement for [1] is to have submodules
checked out, which is a rather strong requirement, as that doesn't
help you when you want to reference multiple superrpojects with
incomplete submodule checkout. (Given all of them together may or
may not produce the full set of references)
    IOW, both layouts are equally sensible; what layout (either one
    of the above two, or something entirely different) is your "at
    the same paths" assumption meant to serve well, and what is the
    plan to serve other layouts?
The plan for other layouts might be

    git submodule update --reference-dir /var/cache/

?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help