From: Max Kirillov <max@max630.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: Max Kirillov <max@max630.net>,
Jacob Keller <jacob.keller@gmail.com>,
git@vger.kernel.org
Subject: Re: [PATCH] describe: teach --match to handle branches and remotes
Date: Wed, 20 Sep 2017 04:07:20 +0300 [thread overview]
Message-ID: <20170920010719.GA12408@jessie.local> (raw)
In-Reply-To: <xmqqzi9rsgxz.fsf@gitster.mtv.corp.google.com>
On Tue, Sep 19, 2017 at 08:52:24AM +0900, Junio C Hamano wrote:
> I think you can use skip_prefix() to avoid counting the length of
> the prefix yourself, i.e.
Thanks, will use it.
> The hardcoded +10 for "is_tag" case assumes that anything other than
> "refs/tags/something" would ever be used to call into this function
> when is_tag is true, and that may well be true in the current code
> and have been so ever since the original code was written, but it
> still smells like an invitation for future bugs.
is_tag is used later. I'll chance it so that it does not
rely on it to match, but it still has to produce it.
> Was there a reason why A and c are in different cases? Are we
> worried about case insensitive filesystems or something?
The tags have been there of different case already. I don't
know why. I'll change the branch names but I'm reluctant to
touch existing tests.
--
Max
next prev parent reply other threads:[~2017-09-20 1:08 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-17 14:24 [PATCH] describe: teach --match to handle branches and remotes Max Kirillov
2017-09-18 23:52 ` Junio C Hamano
2017-09-19 0:45 ` Jacob Keller
2017-09-20 1:07 ` Max Kirillov [this message]
2017-09-20 1:10 ` [PATCH v2] " Max Kirillov
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
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170920010719.GA12408@jessie.local \
--to=max@max630.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jacob.keller@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.
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).