From: Jeff King <peff@peff.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: "Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>,
git@vger.kernel.org, "Jonathan Nieder" <jrnieder@gmail.com>
Subject: Re: [PATCH WIP 0/3] git log --exclude
Date: Thu, 6 Oct 2011 10:34:41 -0400 [thread overview]
Message-ID: <20111006143441.GA21558@sigill.intra.peff.net> (raw)
In-Reply-To: <7vhb3n8ie9.fsf@alter.siamese.dyndns.org>
On Wed, Oct 05, 2011 at 10:20:30AM -0700, Junio C Hamano wrote:
> The way I envisioned the narrow cloning would work like this [*1*]:
>
> * The narrowed set of paths is an attribute of the local repository. It
> is not tied to the history nor the current working tree state, so the
> information does not live in the index or in the history. A new file
> $GIT_DIR/narrowed-paths specifies a list of pathspecs. We call a
> repository with such a file "a narrowed repository".
>
> * The objects that live in a narrowed repository are subset of the
> objects in an unnarrowed repository that records the same
> history. Objects are not modified in any way when transferring into
> a narrowed repository. E.g. if you clone git.git but limit the tree to
> Documentation/ and builtin/, you will get _all_ commit objects, even
> the ones that do _not_ touch these two directories, and the top level
> tree objects. These top level tree objects _do_ record the object names
> for paths outside the narrowed area. To facilitate local history
> traversal, we may add either grafts or replace entries to "gather" away
> commits that do not touch the narrowed area, but this is not essential.
I'm really just a bystander on this topic, and haven't given it too much
thought. But one stumbling block I see for narrow clone is how narrow
repositories will interact with object transfer from other repositories.
For example, if I have a narrow git.git that omits Documentation, and I
do a "git fetch" from a non-narrow repository, then how do we tell the
non-narrow remote that we don't have blobs in Documentation, and that
they should not be used as delta bases for any objects that are sent?
The current protocol relies on certain repository properties on the
remote end that narrow clone will violate. I don't see a way around that
without a protocol extension to communicate the narrowness. What will
that extension look like?
-Peff
next prev parent reply other threads:[~2011-10-06 14:34 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-05 7:18 [PATCH WIP 0/3] git log --exclude Nguyễn Thái Ngọc Duy
2011-10-05 7:18 ` [PATCH WIP 1/3] diff-no-index: rename read_directory to avoid conflict from dir.h Nguyễn Thái Ngọc Duy
2011-10-05 7:18 ` [PATCH WIP 2/3] tree-diff: teach it to understand exclude patterns Nguyễn Thái Ngọc Duy
2011-10-05 7:18 ` [PATCH WIP 3/3] log: add --exclude option Nguyễn Thái Ngọc Duy
2011-10-05 8:08 ` [PATCH WIP 0/3] git log --exclude Matthieu Moy
2011-10-05 8:28 ` Nguyen Thai Ngoc Duy
2011-10-05 17:20 ` Junio C Hamano
2011-10-06 14:34 ` Jeff King [this message]
2011-10-06 17:22 ` Junio C Hamano
2011-10-06 21:47 ` Nguyen Thai Ngoc Duy
2011-10-07 7:16 ` Nguyen Thai Ngoc Duy
2011-10-07 17:57 ` Junio C Hamano
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=20111006143441.GA21558@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jrnieder@gmail.com \
--cc=pclouds@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).