public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox•com>
To: Lukas Fleischer <lfleischer@lfos•de>
Cc: git@vger•kernel.org, Jeff King <peff@peff•net>,
	Eric Sunshine <sunshine@sunshineco•com>
Subject: Re: [PATCH v2 3/4] Add support for matching full refs in hideRefs
Date: Wed, 04 Nov 2015 11:09:10 -0800	[thread overview]
Message-ID: <xmqqy4eda8fd.fsf@gitster.mtv.corp.google.com> (raw)
In-Reply-To: <xmqqd1vqdc7c.fsf@gitster.mtv.corp.google.com> (Junio C. Hamano's message of "Tue, 03 Nov 2015 13:07:03 -0800")

Junio C Hamano <gitster@pobox•com> writes:

> The semantics of "hideRefs" used to be that "refs can be hidden from
> ls-remote" (i.e. prevents fetching, avoids contaminating "--mirror")
> and "refs can be hidden from 'push'", but the objects being known
> tips of histories that are complete, they still participate in
> common ancestor discovery.  
>
>> diff --git a/Documentation/config.txt b/Documentation/config.txt
>> index 3da97a1..91ed6a5 100644
>> --- a/Documentation/config.txt
>> +++ b/Documentation/config.txt
>> @@ -2690,7 +2690,8 @@ the prefix `refs/heads/master` is specified in `transfer.hideRefs` and the
>>  current namespace is `foo`, then `refs/namespaces/foo/refs/heads/master` is
>>  omitted from the advertisements but `refs/heads/master` and
>>  `refs/namespaces/bar/refs/heads/master` are still advertised as so-called
>> -"have" lines.
>> +"have" lines. In order to match refs before stripping, add a `^` in front of
>> +the ref name. If you combine `!` and `^`, `!` must be specified first.
>
> I think the changes in the above two hunks prevent the hidden refs
> from participating in common ancestor discovery (which is probably a
> good thing), making the above description stale.

Ah, I was confused.  The description only says "refs from outer
namespaces are not advertised, but still participate the common
ancestor discovery in the form of .have lines", and moving the
location where ref-is-hidden is called in this patch does not affect
that fact at all.

So this looks good as-is.

Thanks.

  reply	other threads:[~2015-11-04 19:09 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-03  7:58 [PATCH v2 0/4] Improve hideRefs when used with namespaces Lukas Fleischer
2015-11-03  7:58 ` [PATCH v2 1/4] Document the semantics of hideRefs " Lukas Fleischer
2015-11-03 21:09   ` Junio C Hamano
2015-11-03  7:58 ` [PATCH v2 2/4] upload-pack: strip refs before calling ref_is_hidden() Lukas Fleischer
2015-11-03  7:58 ` [PATCH v2 3/4] Add support for matching full refs in hideRefs Lukas Fleischer
2015-11-03 21:07   ` Junio C Hamano
2015-11-04 19:09     ` Junio C Hamano [this message]
2015-11-03  7:58 ` [PATCH v2 4/4] t5509: add basic tests for hideRefs Lukas Fleischer
2015-11-04 19:36   ` Eric Sunshine
2015-11-04 19:50     ` 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=xmqqy4eda8fd.fsf@gitster.mtv.corp.google.com \
    --to=gitster@pobox$(echo .)com \
    --cc=git@vger$(echo .)kernel.org \
    --cc=lfleischer@lfos$(echo .)de \
    --cc=peff@peff$(echo .)net \
    --cc=sunshine@sunshineco$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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