From: Johannes Schindelin <Johannes.Schindelin@gmx.de>
To: Junio C Hamano <gitster@pobox.com>
Cc: "Kristian Høgsberg" <krh@redhat.com>,
"Daniel Barkalow" <barkalow@iabervon.org>,
git@vger.kernel.org
Subject: Re: [PATCH] builtin-clone: Implement git clone as a builtin command.
Date: Wed, 12 Dec 2007 11:12:50 +0000 (GMT) [thread overview]
Message-ID: <Pine.LNX.4.64.0712121103510.27959@racer.site> (raw)
In-Reply-To: <7vejdsbo7d.fsf@gitster.siamese.dyndns.org>
[-- Attachment #1: Type: TEXT/PLAIN, Size: 3184 bytes --]
Hi,
On Tue, 11 Dec 2007, Junio C Hamano wrote:
> Kristian Høgsberg <krh@redhat.com> writes:
>
> > On Tue, 2007-12-11 at 15:59 -0500, Daniel Barkalow wrote:
> >> On Tue, 11 Dec 2007, Kristian Høgsberg wrote:
> >>
> >> > Ok, don't flame me, I know this isn't appropriate at the moment
> >> > with stabilization for 1.5.4 going on, but I just wanted to post a
> >> > heads up on this work to avoid duplicate effort. It's one big
> >> > patch at this point and I haven't even run the test suite yet, but
> >> > that will change.
> >>
> >> Is that why you misspelled Junio's email address? :)
> >
> > Hehe, yeah, do not mess with maintainers in release mode :)
>
> Actually this is a bit unfortunate, regardless of everybody being in
> release and bugfix only mode.
I can understand that feeling, but I have to say that I am actually quite
pleased with the progress in direction of having most of git as builtins.
> I was hoping that the evolution path for clone would be to first make it
> a very thin wrapper around:
>
> git init
> git remote add -f
> git checkout
>
> sequence.
Yeah, I thought so too, but I'll also gladly take the builtin first.
> There are a handful issues in that approach with the current git-remote,
> and that was why I also thought recent "git remote in C" by Dscho a bit
> unfortunate, as enhancements and interface fixes (both user and machine)
> tend to be much easier in scripted version.
And here I have to disagree strongly. I _wasted_ a _week_ on trying to
fix that stupid "add --mirror && prune" bug in the scripted version. It
was absolutely horrible. And I felt like a moron after that week.
In contrast, it was easy as chocolate cake to fix it in the builtin
remote.
Now, if you not only hinted in some mail that something is wrong with
builtin-remote, but gave me some input, I could fix that in the builtin,
too.
> What the current "git clone" does that are not naturally expressed by
> the above sequence are:
>
> * HEAD discovery
>
> The code can be lifted from the scripted version and transplanted to
> git-remote. And to make "origin" and other remotes added by "git
> remote add", this logic needs to be moved to "git remote".
>
> However, before rewriting the "git remote" to C, it would be really
> nice if we can update the native protocol so that we can reliably
> find out which branch HEAD points at. The current code guesses, only
> because the native protocol does not carry that information [*1*].
> Worse yet, even though the current code _knows_ this information when
> going over dumb protocols, it discards it to use the same guessing
> logic as used by the native protocol.
I wonder why this should be easier with git remote in Perl. IMHO it is
easier with git remote in C.
> * --shared optimization
>
> This is a very easy addition to "git remote add". You make sure that
> the added remote repository is on a local machine, and set up
> alternates to point at its object store.
Concur.
Since I want to lose that dependency on cpio on Windows (which we fake by
using tar), I'll implement this in C anyway.
Ciao,
Dscho
next prev parent reply other threads:[~2007-12-12 11:13 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-11 19:57 [PATCH] builtin-clone: Implement git clone as a builtin command Kristian Høgsberg
2007-12-11 20:59 ` Daniel Barkalow
2007-12-11 23:38 ` Kristian Høgsberg
2007-12-12 3:12 ` Junio C Hamano
2007-12-12 3:20 ` Junio C Hamano
2007-12-12 11:12 ` Johannes Schindelin [this message]
2007-12-12 15:04 ` Kristian Høgsberg
2007-12-12 18:24 ` Johannes Schindelin
2007-12-12 15:24 ` Kristian Høgsberg
2007-12-12 18:00 ` Daniel Barkalow
2007-12-12 18:25 ` Kristian Høgsberg
2007-12-12 18:40 ` Daniel Barkalow
2007-12-24 1:52 ` J. Bruce Fields
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=Pine.LNX.4.64.0712121103510.27959@racer.site \
--to=johannes.schindelin@gmx.de \
--cc=barkalow@iabervon.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=krh@redhat.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).