All of lore.kernel.org
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Jeff King <peff@peff.net>
Cc: Brian Norris <computersforpeace@gmail.com>, git@vger.kernel.org
Subject: Re: git-fetch: default globally to --no-tags
Date: Wed, 19 Nov 2014 12:22:36 -0800	[thread overview]
Message-ID: <xmqqa93nrldf.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <20141119185708.GA9908@peff.net> (Jeff King's message of "Wed, 19 Nov 2014 13:57:09 -0500")

Jeff King <peff@peff.net> writes:

> On Wed, Nov 19, 2014 at 10:45:48AM -0800, Junio C Hamano wrote:
>
>> ... tags are meant to be used for globally shared
>> anchoring points and the whole machinery (e.g. "fetch" that
>> auto-follows tags, "clone" that gives refs/tags*:refs/tags/*
>> refspec) is geared towards supporting that use pattern, which will
>> be broken by moving tags to per-remote namespace.
>> 
>> I can see "git tag --local foo" that creates refs/local-tags/foo
>> and also adding a mechanism to propagate local-tags/ hierarchy just
>> like heads/ hierarchy is propagated per-remote as a solution to that
>> problem that does not break the "release tags" use case, though.
>
> I am not sure I agree here that the discussions in [2] were not handling
> this case. Here you are arguing for the tag-writer to distinguish
> between two separate namespaces: global and local.
>
> But I think the proposals in [2] were about pushing that logic into the
> lookup phase. That is, pulling in all of the remote's tags as
> "refs/remotes/origin/tags/*", and then at lookup time checking multiple
> locations for tags (and preferring your local "refs/tags" to what is
> pulled from a remote).

With a separate local-tags hierarchy, the look-up part still has to
be enhanced.  After doing "git tag v2.0" and "git tag -l snapshot00",
you would want to be able to say "git log snapshot00..v2.0" and have
these found.

If you don't allow a private local-tags hierarchy, then those who
make releases are burdened to be very careful not to contaminate
their public repository --- "git tag snapshot00" cannot be used by
them lightly just to mark their private state, if their day
typically is concluded with "git push --follow-tags", as that will
push out the "tags" that are meant to be private.

Aside from the mantra that it is a good thing to reduce the workload
for people closer to the center of the project (hence likely to be
bottleneck to slow down others) and a separate local-tags hierarchy
is a way to achieve that, a separate local-tags hierarchy also helps
people who do not make releases by letting them easily differenciate
the global tags they get from the project and the tags they and
other project participants create as private markers (their own will
be found in refs/local-tags, others' in refs/remotes/$pal/local-tags).

> ...
> But the superproject is pulling them both together; if it uses
> refs/tags, the global namespaces will clash. Instead, it would be more
> convenitn to have refs/remotes/project1/tags and so on.

Yeah, but isn't it an orthogonal issue?  refs/tags/project{1,2}/*
would be what I would recommend to use for "global" stuff whose
purpose is to give people a shared world view.

  reply	other threads:[~2014-11-19 20:22 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-19  3:05 git-fetch: default globally to --no-tags Brian Norris
2014-11-19 18:42 ` Jeff King
2014-11-19 18:45 ` Junio C Hamano
2014-11-19 18:57   ` Jeff King
2014-11-19 20:22     ` Junio C Hamano [this message]
2014-11-19 20:32       ` Jeff King

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=xmqqa93nrldf.fsf@gitster.dls.corp.google.com \
    --to=gitster@pobox.com \
    --cc=computersforpeace@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=peff@peff.net \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.