git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* Is there a way to get 'git fetch --no-tags' semantics with 'git clone'?
@ 2017-04-14 21:28 Ævar Arnfjörð Bjarmason
  2017-04-18 19:15 ` [PATCH] clone: add a --no-tags option to clone without tags Ævar Arnfjörð Bjarmason
  0 siblings, 1 reply; 11+ messages in thread
From: Ævar Arnfjörð Bjarmason @ 2017-04-14 21:28 UTC (permalink / raw)
  To: Git Mailing List

As far as I can tell the only way to clone a given upstream repo,
which has an unknown main branch name without any tags is:

    git clone --single-branch <url> <repo> &&
    cd <repo> &&
    git tag -d $(git tag -l) &&
    git config remote.origin.tagOpt --no-tags

Is there really nothing like:

    git clone --single-branch --no-tags <url> <repo>

?

I suppose this can be done with the usual 'git init`, set the config &
then fetch dance, but in that case what part of 'git remote' or
friends exposes finding the remote "main" ref as --single-branch does?

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2017-04-26  8:56 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-14 21:28 Is there a way to get 'git fetch --no-tags' semantics with 'git clone'? Ævar Arnfjörð Bjarmason
2017-04-18 19:15 ` [PATCH] clone: add a --no-tags option to clone without tags Ævar Arnfjörð Bjarmason
2017-04-18 21:06   ` Ævar Arnfjörð Bjarmason
2017-04-18 23:30   ` Brandon Williams
2017-04-19  1:38   ` Junio C Hamano
2017-04-19  5:32     ` Junio C Hamano
2017-04-19 14:38     ` [PATCH v2] " Ævar Arnfjörð Bjarmason
2017-04-25 22:45       ` Jonathan Nieder
2017-04-26  1:26         ` Junio C Hamano
2017-04-26  8:56         ` Ævar Arnfjörð Bjarmason
2017-04-25 22:35   ` [PATCH] " Jonathan Nieder

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).