Imported Upstream version 2.1.0
[platform/upstream/git.git] / run-command.h
index 850c638..ea73de3 100644 (file)
@@ -5,8 +5,11 @@
 #include <pthread.h>
 #endif
 
+#include "argv-array.h"
+
 struct child_process {
        const char **argv;
+       struct argv_array args;
        pid_t pid;
        /*
         * Using .in, .out, .err:
@@ -45,7 +48,14 @@ 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, ...);
+extern char *find_hook(const char *name);
+LAST_ARG_MUST_BE_NULL
+extern int run_hook_le(const char *const *env, const char *name, ...);
+extern int run_hook_ve(const char *const *env, const char *name, va_list args);
+
+LAST_ARG_MUST_BE_NULL
+__attribute__((deprecated))
+extern int run_hook_with_custom_index(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 */