From: Jens Lehmann <Jens.Lehmann@web.de>
To: Samuel Maftoul <samuel.maftoul@gmail.com>
Cc: git <git@vger.kernel.org>
Subject: Re: git clone submodules recursive and reference
Date: Fri, 20 Apr 2012 20:59:54 +0200 [thread overview]
Message-ID: <4F91B22A.9000507@web.de> (raw)
In-Reply-To: <CAFj+z055ZZc-Am+pEMgjRvHgoxKSRBjnHhABCseC45+8YswKWg@mail.gmail.com>
Am 20.04.2012 17:12, schrieb Samuel Maftoul:
> Hello,
>
> I'm using git clone --reference, it works like a charm !
>
> Now, I have submodules, so I call git clone with both --recursive and
> --reference, works only for the repo itself, submodules are being
> cloned without the "--reference" option.
>
> With GIT_TRACE=1 I can see this for the initial repo:
>
> trace: built-in: git 'clone' '--recursive' '--reference' [...]
>
> And this for the submodules:
>
> trace: built-in: git 'clone' '-n' [...]
>
> for every submodules.
>
> Is this an intended behavior ?
Hmm, to me it looks like passing the --reference option to the clone
run in the submodules doesn't make much sense, as that would make
all submodules and the superproject use the same alternates. And as
far as I know sharing objects between different repositories is not
supported.
> How can I force the clones for submodules to be executed with the
> --reference option ?
You'd have to use "git clone" without the --recursive option and
then do a "git submodule update --init --reference ...".
next prev parent reply other threads:[~2012-04-20 19:00 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-04-20 15:12 git clone submodules recursive and reference Samuel Maftoul
2012-04-20 18:59 ` Jens Lehmann [this message]
2012-04-20 19:26 ` Samuel Maftoul
2012-04-21 13:45 ` Jens Lehmann
2012-04-23 8:06 ` Samuel Maftoul
2012-04-23 21:20 ` Jens Lehmann
2012-06-29 20:19 ` Phil Hord
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F91B22A.9000507@web.de \
--to=jens.lehmann@web.de \
--cc=git@vger.kernel.org \
--cc=samuel.maftoul@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).