From: Junio C Hamano Date: Tue, 10 Mar 2026 21:23:18 +0000 (-0700) Subject: Merge branch 'ar/config-hooks' X-Git-Tag: v2.54.0-rc0~99 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f330d46deeb143b6109143f37a47d025475d11d6;p=thirdparty%2Fgit.git Merge branch 'ar/config-hooks' Allow hook commands to be defined (possibly centrally) in the configuration files, and run multiple of them for the same hook event. * ar/config-hooks: hook: add -z option to "git hook list" hook: allow out-of-repo 'git hook' invocations hook: allow event = "" to overwrite previous values hook: allow disabling config hooks hook: include hooks from the config hook: add "git hook list" command hook: run a list of hooks to prepare for multihook support hook: add internal state alloc/free callbacks --- f330d46deeb143b6109143f37a47d025475d11d6 diff --cc git.c index 744cb6527e,a9e462ee32..6480ff8373 --- a/git.c +++ b/git.c @@@ -586,8 -586,7 +586,8 @@@ static struct cmd_struct commands[] = { "grep", cmd_grep, RUN_SETUP_GENTLY }, { "hash-object", cmd_hash_object }, { "help", cmd_help }, + { "history", cmd_history, RUN_SETUP }, - { "hook", cmd_hook, RUN_SETUP }, + { "hook", cmd_hook, RUN_SETUP_GENTLY }, { "index-pack", cmd_index_pack, RUN_SETUP_GENTLY | NO_PARSEOPT }, { "init", cmd_init_db }, { "init-db", cmd_init_db },