From: Vitor Antunes <vitor.hda@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org, Pete Wyckoff <pw@padd.com>,
Tor Arvid Lund <torarvid@gmail.com>
Subject: Re: [PATCH v2 1/4] git-p4: Allow setting rename/copy detection threshold.
Date: Fri, 19 Aug 2011 00:43:12 +0100 [thread overview]
Message-ID: <CAOpHH-VsoOSOH6ym2exCH=W4NmuKRw+f53HrwB47YD3u-iDe2w@mail.gmail.com> (raw)
In-Reply-To: <7vy5yq5nkb.fsf@alter.siamese.dyndns.org>
On Fri, Aug 19, 2011 at 12:04 AM, Junio C Hamano <gitster@pobox.com> wrote:
> This is not a new problem you introduced with this patch, but unless you
> are invoking "git config --bool" in your gitConfig() (I didn't bother to
> check), you will misunderstand different ways to say "Yes", e.g.
>
> [git-p4]
> detectRenames
> detectRenames = on
> detectRenames = yes
> detectRenames = 1
>
> If you use --bool, you can rely on the values being either true or false,
> and do not have to do the .lower() thing.
>
Now that I look at this carefully, Tor added the possibility to add arguments to
gitConfig() exactly for that purpose. This is helpful for processing the
detectCopiesHarder option I added.
For detectRenames and detectCopies it is a bit more complex. I think that if I
use --bool or --bool-or-int then it is possible that certain values will fail to
be processed. Let me give you some examples:
[git-p4]
detectRenames = true
detectRenames = 80%
detectRenames = 80
detectRenames = 1%
detectRenames = 1
It will be difficult for me to, for example, to understand if a 1 represents 1%
or true. Or am I overcomplicating this? :)
Thanks,
--
Vitor Antunes
next prev parent reply other threads:[~2011-08-18 23:43 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-18 22:20 [PATCH v2 0/4] Support threshold in copy/rename detection Vitor Antunes
2011-08-18 22:20 ` [PATCH v2 1/4] git-p4: Allow setting rename/copy detection threshold Vitor Antunes
2011-08-18 23:04 ` Junio C Hamano
2011-08-18 23:43 ` Vitor Antunes [this message]
2011-08-19 11:47 ` Pete Wyckoff
2011-08-19 13:51 ` Vitor Antunes
2011-08-20 11:19 ` Pete Wyckoff
2011-08-22 0:09 ` Vitor Antunes
2011-08-18 22:20 ` [PATCH v2 2/4] git-p4: Add description of rename/copy detection options Vitor Antunes
2011-08-18 22:20 ` [PATCH v2 3/4] git-p4: Add test case for rename detection Vitor Antunes
2011-08-18 22:20 ` [PATCH v2 4/4] git-p4: Add test case for copy detection Vitor Antunes
2011-08-20 19:09 ` [PATCH v2 0/4] Support threshold in copy/rename detection Pete Wyckoff
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='CAOpHH-VsoOSOH6ym2exCH=W4NmuKRw+f53HrwB47YD3u-iDe2w@mail.gmail.com' \
--to=vitor.hda@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=pw@padd.com \
--cc=torarvid@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).