From: Jeff King <peff@peff.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: Lars Schneider <larsxschneider@gmail.com>,
Git Users <git@vger.kernel.org>
Subject: Re: [RFC] Case insensitive URL rewrite
Date: Fri, 11 Dec 2015 14:15:13 -0500 [thread overview]
Message-ID: <20151211191512.GA5361@sigill.intra.peff.net> (raw)
In-Reply-To: <xmqq7fkkg7tq.fsf@gitster.mtv.corp.google.com>
On Fri, Dec 11, 2015 at 10:26:41AM -0800, Junio C Hamano wrote:
> Lars Schneider <larsxschneider@gmail.com> writes:
>
> > What do you think about a flag that makes these rewrites case insensitive? E.g. with the following config flag:
> >
> > [url "<actual url base>"]
> > insteadOf = <other url base>
> > ignorecase = true
>
> I am with Daniel on this.
>
> It is perfectly fine to consider these two equivalent.
>
> git clone https://github.com/git/git (canonical one)
> git clone https://GitHub.com/git/git (host part in funny case)
>
> In fact, I think we should do this without any additional
> configuration variable.
>
> On the other hand, these two MUST be treated as different by
> default:
>
> git clone https://github.com/GIT/GIT (differences outside host part)
> git clone git@github.com:GIT/GIT (differences outside host part)
I haven't looked, but the code in urlmatch.c probably gets all of this
right already. It was written much later than the insteadOf code, as it
was part of the http.$url.* matching, and it may be reasonable to simply
teach the insteadOf code to use it. OTOH, it may need tweaked because
I'm not sure how it would handle non-URLs like the "host:path" ssh form.
-Peff
prev parent reply other threads:[~2015-12-11 19:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-11 13:45 [RFC] Case insensitive URL rewrite Lars Schneider
2015-12-11 14:38 ` Daniel Stenberg
2015-12-11 18:26 ` Junio C Hamano
2015-12-11 18:51 ` Stefan Beller
2015-12-11 18:56 ` Junio C Hamano
2015-12-11 19:15 ` Jeff King [this message]
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=20151211191512.GA5361@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=larsxschneider@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).