From: Junio C Hamano <gitster@pobox.com>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: Mark Levedahl <mlevedahl@gmail.com>, git@vger.kernel.org
Subject: Re: [PATCH 0 of 7] [resend] - Improve handling remotes, origin, submodules
Date: Mon, 04 Feb 2008 13:40:44 -0800 [thread overview]
Message-ID: <7v1w7sjt7n.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <alpine.LSU.1.00.0802042027470.8543@racer.site> (Johannes Schindelin's message of "Mon, 4 Feb 2008 20:47:26 +0000 (GMT)")
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> AFAICT "clone -o" was meant _only_ for this scenario:
>
> You have a slow connection, but someone can provide you with a thumb
> drive, having the current repository.
>
> You clone it from the thumb drive, but of course you want to use your
> (slow) connection for subsequent updates (i.e. you want to have a
> different default remote).
>
> What you do is
>
> $ git clone -o thumbdrive /media/usbdisk/that-repository.git/
>
> Then, to be able to update from your preferred remote quickly, you add the
> proper remote:
>
> $ git remote add --fetch origin git://git.kernel.org/shlub.git/
>
> In my understanding, this scenario is the only reason to live for clone's
> -o option, and it would be actively wrong for it to change the _name_ of
> the default remote to "thumbdrive".
Then we should fix "git-clone".
If you do the first command, I am reasonably sure that you would
get:
[branch "master"]
remote = thumbdrive
in your .git/config. You may want to occasionally go back to
thumbdrive for sneakernetting, so I do not think we should
remove [remote "thumbdrive"] section the clone would leave, but
the above "master branch would interact with thumbdrive
repository" should not be there.
And that corrected behaviour and the intended use of -o should
be documented.
next prev parent reply other threads:[~2008-02-04 21:41 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-03 17:31 [PATCH 0 of 7] [resend] - Improve handling remotes, origin, submodules Mark Levedahl
2008-02-03 17:31 ` [PATCH 1/7] Teach remote machinery about core.origin config variable Mark Levedahl
2008-02-03 17:31 ` [PATCH 2/7] git-remote - Unset core.origin when deleting the default remote Mark Levedahl
2008-02-03 17:31 ` [PATCH 3/7] git-clone - Set remotes.origin config variable Mark Levedahl
2008-02-03 17:31 ` [PATCH 4/7] git-submodule - Possibly inherit parent's default remote on init/clone Mark Levedahl
2008-02-03 17:31 ` [PATCH 5/7] Teach git-submodule to use top-level remote when updating subprojects Mark Levedahl
2008-02-03 17:31 ` [PATCH 6/7] git-submodule - Allow adding a submodule in-place Mark Levedahl
2008-02-03 17:31 ` [PATCH 7/7] Add t/t7401 - test submodule interaction with remotes machinery Mark Levedahl
2008-02-03 22:43 ` [PATCH 0 of 7] [resend] - Improve handling remotes, origin, submodules Johannes Schindelin
2008-02-04 3:52 ` Mark Levedahl
2008-02-04 14:48 ` Johannes Schindelin
2008-02-04 17:24 ` Mark Levedahl
2008-02-04 18:15 ` Johannes Schindelin
2008-02-04 19:59 ` Junio C Hamano
2008-02-04 20:47 ` Johannes Schindelin
2008-02-04 21:40 ` Junio C Hamano [this message]
2008-02-04 21:49 ` Johannes Schindelin
2008-02-04 5:19 ` Steffen Prohaska
2008-02-04 14:55 ` 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=7v1w7sjt7n.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
--cc=mlevedahl@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).