[PATCH v1 3/3] read-cache: Add documentation for the post-indexchanged hook
- Date: Fri, 8 Feb 2019 14:51:15 -0500
- From: Ben Peart <peartben@xxxxxxxxx>
- Subject: [PATCH v1 3/3] read-cache: Add documentation for the post-indexchanged hook
From: Kevin Willford <kewillf@xxxxxxxxxxxxx>
Document the new post-indexchanged hook with information on when it is
called as well as the flags passed and what each of them mean.
Signed-off-by: Kevin Willford <kewillf@xxxxxxxxxxxxx>
Signed-off-by: Ben Peart <benpeart@xxxxxxxxxxxxx>
Documentation/githooks.txt | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/Documentation/githooks.txt b/Documentation/githooks.txt
index 959044347e..9349cd8900 100644
@@ -492,6 +492,24 @@ This hook is invoked by `git-p4 submit`. It takes no parameters and nothing
from standard input. Exiting with non-zero status from this script prevent
`git-p4 submit` from launching. Run `git-p4 submit --help` for details.
+This hook is invoked when the index is written in read-cache.c
+The first parameter passed to the hook is the indicator for the
+working directory being updated. "1" meaning working directory
+was updated or "0" when the working directory was not updated.
+The second parameter passed to the hook is the indicator for whether
+or not the index was updated and the skip-worktree bit could have
+changed. "1" meaning skip-worktree bits could have been updated
+and "0" meaning they were not.
+Only one parameter should be set to "1" when the hook runs. The hook
+running passing "1", "1" should not be possible.
Part of the linkgit:git suite