aboutsummaryrefslogtreecommitdiff
path: root/Documentation/config
diff options
context:
space:
mode:
authorAdrian Ratiu <adrian.ratiu@collabora.com>2026-02-19 00:23:50 +0200
committerJunio C Hamano <gitster@pobox.com>2026-02-19 13:23:41 -0800
commitd084fa2a915784d65257fbaff43f00b3ea5c8a44 (patch)
treea21cc77ed137445de0ff142b3c609a1585f4c643 /Documentation/config
parent1ecce722cdb9c42dd4c69e45e02cb850cd558ef2 (diff)
downloadgit-d084fa2a915784d65257fbaff43f00b3ea5c8a44.tar.xz
hook: allow event = "" to overwrite previous values
Add the ability for empty events to clear previously set multivalue variables, so the newly added "hook.*.event" behave like the other multivalued keys. Suggested-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Adrian Ratiu <adrian.ratiu@collabora.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/config')
-rw-r--r--Documentation/config/hook.adoc4
1 files changed, 3 insertions, 1 deletions
diff --git a/Documentation/config/hook.adoc b/Documentation/config/hook.adoc
index 0cda4745a6..64e845a260 100644
--- a/Documentation/config/hook.adoc
+++ b/Documentation/config/hook.adoc
@@ -12,7 +12,9 @@ hook.<name>.event::
linkgit:githooks[5] for a complete list of hook events.) On the
specified event, the associated `hook.<name>.command` is executed.
This is a multi-valued key. To run `hook.<name>` on multiple
- events, specify the key more than once. See linkgit:git-hook[1].
+ events, specify the key more than once. An empty value resets
+ the list of events, clearing any previously defined events for
+ `hook.<name>`. See linkgit:git-hook[1].
hook.<name>.enabled::
Whether the hook `hook.<name>` is enabled. Defaults to `true`.