All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shawn Pearce <spearce@spearce.org>
To: git@vger.kernel.org
Subject: Re: git clone downloads objects that are in GIT_OBJECT_DIRECTORY
Date: Sun, 5 Mar 2006 20:42:53 -0500	[thread overview]
Message-ID: <20060306014253.GD25790@spearce.org> (raw)
In-Reply-To: <20060306010825.GF20768@kvack.org>

Benjamin LaHaise <bcrl@kvack.org> wrote:
> Hi folks,
> 
> Doing a fresh git clone git://some.git.url/ foo seems to download the 
> entire remote repository even if all the objects are already stored in 
> GIT_OBJECT_DIRECTORY=/home/bcrl/.git/object .  Is this a known bug?  
> At 100MB for a kernel, this takes a *long* time.

I believe it is a known missing feature.  :-) git-clone doesn't
prep HEAD to have some sort of starting point so the pull it uses
to download everything literally downloads everything as nothing
is in common.

One could work around it by running git-init-db to create the new
clone locally, git-update-ref HEAD to some commit which you have in
common with the remote, create a origin file, then perform a git-pull.
This would only download the objects between the commit you put into
HEAD and the current master of the remote...  But that is actually
some work.

I think Cogito's clone is capable of restarting a failed clone; I
wonder if that logic would benefit you here?

Is using a common GIT_OBJECT_DIRECTORY across many clones actually
pretty common?  Maybe its time that git-clone gets some more smarts
with regards to what it yanks from the origin.

-- 
Shawn.

  reply	other threads:[~2006-03-06  1:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-06  1:08 git clone downloads objects that are in GIT_OBJECT_DIRECTORY Benjamin LaHaise
2006-03-06  1:42 ` Shawn Pearce [this message]
2006-03-06  2:34   ` Junio C Hamano
2006-03-06  2:57     ` Shawn Pearce
2006-03-06  3:31       ` sean
2006-03-06  3:31         ` sean
2006-03-06  9:20           ` Johannes Schindelin

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=20060306014253.GD25790@spearce.org \
    --to=spearce@spearce.org \
    --cc=git@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.