X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=run-command.h;h=15e870a65eb037cd49d1e01251711915da06d260;hb=1d4e4cd4a108dc105f6c8e739c69b9261d4e92a5;hp=a8b0c209e9b7487ce3c2b214cbebe7ad4f97fd11;hpb=8abc61880d34f7a85928d7ca95cb1165b2aca1df;p=git.git diff --git a/run-command.h b/run-command.h index a8b0c209e..15e870a65 100644 --- a/run-command.h +++ b/run-command.h @@ -10,6 +10,7 @@ enum { ERR_RUN_COMMAND_WAITPID_SIGNAL, ERR_RUN_COMMAND_WAITPID_NOEXIT, }; +#define IS_RUN_COMMAND_ERR(x) ((x) <= -ERR_RUN_COMMAND_FORK) struct child_process { const char **argv; @@ -49,6 +50,8 @@ int start_command(struct child_process *); int finish_command(struct child_process *); int run_command(struct child_process *); +extern int run_hook(const char *index_file, const char *name, ...); + #define RUN_COMMAND_NO_STDIN 1 #define RUN_GIT_CMD 2 /*If this is to be git sub-command */ #define RUN_COMMAND_STDOUT_TO_STDERR 4