* [PATCH] sample pre-commit hook: Use --bool when retrieving config var
@ 2013-09-24 7:52 Johan Herland
2013-09-24 19:22 ` Jonathan Nieder
0 siblings, 1 reply; 4+ messages in thread
From: Johan Herland @ 2013-09-24 7:52 UTC (permalink / raw)
To: jrnieder; +Cc: git, johan
Signed-off-by: Johan Herland <johan@herland.net>
---
Resend/reminder...
...Johan
templates/hooks--pre-commit.sample | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/templates/hooks--pre-commit.sample b/templates/hooks--pre-commit.sample
index 586e3bf..68d62d5 100755
--- a/templates/hooks--pre-commit.sample
+++ b/templates/hooks--pre-commit.sample
@@ -16,7 +16,7 @@ else
fi
# If you want to allow non-ASCII filenames set this variable to true.
-allownonascii=$(git config hooks.allownonascii)
+allownonascii=$(git config --bool hooks.allownonascii)
# Redirect output to stderr.
exec 1>&2
--
1.8.1.rc2.269.g5aaac94
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] sample pre-commit hook: Use --bool when retrieving config var
2013-09-24 7:52 [PATCH] sample pre-commit hook: Use --bool when retrieving config var Johan Herland
@ 2013-09-24 19:22 ` Jonathan Nieder
2013-09-25 10:10 ` Johan Herland
0 siblings, 1 reply; 4+ messages in thread
From: Jonathan Nieder @ 2013-09-24 19:22 UTC (permalink / raw)
To: Johan Herland; +Cc: git
Johan Herland wrote:
> Signed-off-by: Johan Herland <johan@herland.net>
Thanks.
What symptoms does this alleviate? Is this to allow configurations like
[hooks]
allowNonAscii = 1
and
[hooks]
allowNonAscii
to do the expected thing, or is it something more subtle than that?
Curious,
Jonathan
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] sample pre-commit hook: Use --bool when retrieving config var
2013-09-24 19:22 ` Jonathan Nieder
@ 2013-09-25 10:10 ` Johan Herland
0 siblings, 0 replies; 4+ messages in thread
From: Johan Herland @ 2013-09-25 10:10 UTC (permalink / raw)
To: Jonathan Nieder; +Cc: Git mailing list
On Tue, Sep 24, 2013 at 9:22 PM, Jonathan Nieder <jrnieder@gmail.com> wrote:
> Johan Herland wrote:
>> Signed-off-by: Johan Herland <johan@herland.net>
>
> Thanks.
>
> What symptoms does this alleviate? Is this to allow configurations like
>
> [hooks]
> allowNonAscii = 1
>
> and
>
> [hooks]
> allowNonAscii
>
> to do the expected thing, or is it something more subtle than that?
Nothing subtle. Just what you list. And for consistency with the other
sample hooks' use of "git config".
...Johan
--
Johan Herland, <johan@herland.net>
www.herland.net
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH] sample pre-commit hook: Use --bool when retrieving config var
@ 2013-09-20 13:53 Johan Herland
0 siblings, 0 replies; 4+ messages in thread
From: Johan Herland @ 2013-09-20 13:53 UTC (permalink / raw)
To: gitster; +Cc: git, johan
Signed-off-by: Johan Herland <johan@herland.net>
---
templates/hooks--pre-commit.sample | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/templates/hooks--pre-commit.sample b/templates/hooks--pre-commit.sample
index 586e3bf..68d62d5 100755
--- a/templates/hooks--pre-commit.sample
+++ b/templates/hooks--pre-commit.sample
@@ -16,7 +16,7 @@ else
fi
# If you want to allow non-ASCII filenames set this variable to true.
-allownonascii=$(git config hooks.allownonascii)
+allownonascii=$(git config --bool hooks.allownonascii)
# Redirect output to stderr.
exec 1>&2
--
1.8.1.rc2.269.g5aaac94
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-09-25 10:11 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-24 7:52 [PATCH] sample pre-commit hook: Use --bool when retrieving config var Johan Herland
2013-09-24 19:22 ` Jonathan Nieder
2013-09-25 10:10 ` Johan Herland
-- strict thread matches above, loose matches on Subject: below --
2013-09-20 13:53 Johan Herland
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.