@matheusbsbs / matheus-bagliano / commits / 35d5ae679c
Fork 0

api-run-command.txt: talk about run_hook()

Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Stephan Beyer committed Jan 16, 2009 at 20:10 UTC 35d5ae679c2a6bc2a5f70f9209844ae8c14ae9e3
1 file changed +15
Documentation/technical/api-run-command.txt
+15
@@ -52,6 +52,21 @@ Functions
52 Wait for the completion of an asynchronous function that was
53 started with start_async().
54
55 +`run_hook`::
56 +
57 + Run a hook.
58 + The first argument is a pathname to an index file, or NULL
59 + if the hook uses the default index file or no index is needed.
60 + The second argument is the name of the hook.
61 + The further arguments (up to 9) correspond to the hook arguments.
62 + The last argument has to be NULL to terminate the arguments list.
63 + If the hook does not exist or is not executable, the return
64 + value will be zero.
65 + If it is executable, the hook will be executed and the exit
66 + status of the hook is returned.
67 + On execution, .stdout_to_stderr and .no_stdin will be set.
68 + (See below.)
69 +
70
71 Data structures
72 ---------------