From: Dmitry Potapov <dpotapov@gmail.com>
To: sverre@rabbelier.nl
Cc: "Björn Steinbrink" <B.Steinbrink@gmx.de>,
"Michael J Gruber" <git@drmicha.warpmail.net>,
"Junio C Hamano" <gitster@pobox.com>,
"Shawn O. Pearce" <spearce@spearce.org>,
"Martin Langhoff" <martin.langhoff@gmail.com>,
"Git Mailing List" <git@vger.kernel.org>
Subject: Re: Grafts workflow for a "shallow" repository...?
Date: Wed, 17 Sep 2008 03:12:32 +0400 [thread overview]
Message-ID: <20080916231232.GK28210@dpotapov.dyndns.org> (raw)
In-Reply-To: <bd6139dc0809161502t121c5aa5la53784bb8ff273a2@mail.gmail.com>
On Wed, Sep 17, 2008 at 12:02:25AM +0200, Sverre Rabbelier wrote:
> On Tue, Sep 16, 2008 at 15:50, Björn Steinbrink <B.Steinbrink@gmx.de> wrote:
> > Maybe instead of providing "pre-shallowed" repos to clone from, that
> > should have been an RFE to support shallow clones starting at a given
> > commit in the DAG? I have no idea whether that's feasible though.
>
> Would it be like grafts, only the graft is set up by the fetcher,
> instead of the host?
No, the idea is to have it in the $GIT_DIR/shallow format, which differs
from grafts in that it cannot add new parents. So, it can only truncate
history, while grafts adding new parents can modify history in different
ways.
> (E.g., the graft is created on clone, instead of
> -before- the clone, by means of the --depth parameter?) Which means
> the mentioned security risk is not there (what with the fetcher
> setting it up himself).
The important difference between grafts and shallow is that the latter
does not allow you to add new parents. So, you cannot modify history but
only truncate existing one. So I am not sure about what security risk
you are talking about. Obviously, that git blame will attribute all
changes that were done before to the earliest downloaded commit. Other
than that, I don't think that you can fake anything here. All downloaded
history will be correct and that can be verified based on SHA-1.
Also, I believe that the default mode should be to ignore this shallow
file on server unless the user specified the corresponding option to
make a shallow copy.
BTW, the current implementation of shallow copy has some limitations.
See Documentation/technical/shallow.txt for details.
Dmitry
next prev parent reply other threads:[~2008-09-16 23:13 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-16 5:09 Grafts workflow for a "shallow" repository...? Martin Langhoff
2008-09-16 5:24 ` Shawn O. Pearce
2008-09-16 6:25 ` Junio C Hamano
2008-09-16 8:09 ` Björn Steinbrink
2008-09-16 13:27 ` Michael J Gruber
2008-09-16 13:50 ` Björn Steinbrink
2008-09-16 22:02 ` Sverre Rabbelier
2008-09-16 23:12 ` Dmitry Potapov [this message]
2008-09-16 19:12 ` Grafts workflow for a Sergio
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=20080916231232.GK28210@dpotapov.dyndns.org \
--to=dpotapov@gmail.com \
--cc=B.Steinbrink@gmx.de \
--cc=git@drmicha.warpmail.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=martin.langhoff@gmail.com \
--cc=spearce@spearce.org \
--cc=sverre@rabbelier.nl \
/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).