diff options
author | Junio C Hamano <gitster@pobox.com> | 2022-02-09 23:21:00 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2022-02-09 23:21:00 +0100 |
commit | c70bc338e9a35b45263c3c68913ad516e9e70d62 (patch) | |
tree | d44d22a30a76b1f825d7b14e36b1e874ba24a922 /read-cache.c | |
parent | Merge branch 'fs/ssh-signing-crlf' (diff) | |
parent | run-command: remove old run_hook_{le,ve}() hook API (diff) | |
download | git-c70bc338e9a35b45263c3c68913ad516e9e70d62.tar.xz git-c70bc338e9a35b45263c3c68913ad516e9e70d62.zip |
Merge branch 'ab/config-based-hooks-2'
More "config-based hooks".
* ab/config-based-hooks-2:
run-command: remove old run_hook_{le,ve}() hook API
receive-pack: convert push-to-checkout hook to hook.h
read-cache: convert post-index-change to use hook.h
commit: convert {pre-commit,prepare-commit-msg} hook to hook.h
git-p4: use 'git hook' to run hooks
send-email: use 'git hook run' for 'sendemail-validate'
git hook run: add an --ignore-missing flag
hooks: convert worktree 'post-checkout' hook to hook library
hooks: convert non-worktree 'post-checkout' hook to hook library
merge: convert post-merge to use hook.h
am: convert applypatch-msg to use hook.h
rebase: convert pre-rebase to use hook.h
hook API: add a run_hooks_l() wrapper
am: convert {pre,post}-applypatch to use hook.h
gc: use hook library for pre-auto-gc hook
hook API: add a run_hooks() wrapper
hook: add 'run' subcommand
Diffstat (limited to 'read-cache.c')
-rw-r--r-- | read-cache.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/read-cache.c b/read-cache.c index ed297635a3..eeb1c9e8f7 100644 --- a/read-cache.c +++ b/read-cache.c @@ -28,6 +28,7 @@ #include "sparse-index.h" #include "csum-file.h" #include "promisor-remote.h" +#include "hook.h" /* Mask for the name length in ce_flags in the on-disk index */ @@ -3150,7 +3151,7 @@ static int do_write_locked_index(struct index_state *istate, struct lock_file *l else ret = close_lock_file_gently(lock); - run_hook_le(NULL, "post-index-change", + run_hooks_l("post-index-change", istate->updated_workdir ? "1" : "0", istate->updated_skipworktree ? "1" : "0", NULL); istate->updated_workdir = 0; |