Re: [PATCH] archive: re-allow HEAD:Documentation on a remote invocation
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jan 12, 2012, 02:46 UTC
- Message-ID
- <7vipkh4oyn.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <1326283958-30271-1-git-send-email-cmn@elego.de>
Carlos Martín Nieto <cmn@elego.de> writes:
> The tightening done in (ee27ca4a: archive: don't let remote clients > get unreachable commits, 2011-11-17) went too far and disallowed > HEAD:Documentation as it would try to find "HEAD:Documentation" as a > ref.
I do not think it went too far. Actually we discussed this exact issue when the topic was cooking, and saw no objections. The commit in question itself advertises this restriction.
Why are we loosening it now? I do not see a compelling reason to do so.
Show 10 quoted lines
> Only DWIM the "HEAD" part to see if it exists as a ref. Once we're > sure that we've been given a valid ref, we follow the normal code > path. This still disallows attempts to access commits which are not > branch tips. > > Signed-off-by: Carlos Martín Nieto <cmn@elego.de> > --- > AFAICT this should still be safe. Using HEAD^:Documentation or > <sha1>:Documentation still complains that HEAD^ and <sha1> aren't > refs.
Having said that, I think I agree this is a safe thing to do, _if_ we want to loosen it.