Reset inheritable flag of debug log file git_shell_ext_debug.txt
[git-cheetah/kirill.git] / common / exec.h
blobd856cade3d9261e440854684857a18971be921b4
2 #define NORMALMODE (0)
3 #define HIDDENMODE (1 << 0) /* hide any windows, opened by execution */
4 #define WAITMODE (1 << 1) /* wait for execution to complete */
5 #define QUIETMODE (1 << 7) /* don't report any errors to user */
7 enum {
8 ERR_RUN_COMMAND_FORK = 10000,
9 ERR_RUN_COMMAND_EXEC,
10 ERR_RUN_COMMAND_PIPE,
11 ERR_RUN_COMMAND_WAITPID,
12 ERR_RUN_COMMAND_WAITPID_WRONG_PID,
13 ERR_RUN_COMMAND_WAITPID_SIGNAL,
14 ERR_RUN_COMMAND_WAITPID_NOEXIT,
18 * Varargs interface to mingw_spawnvpe with NULL as end-of-format indicator.
20 * - supports specifying working directory;
21 * - supports different modes of operation (see NORMALMODE & co. above).
23 int exec_program(const char *working_directory,
24 struct strbuf *output, struct strbuf *error_output,
25 int flags, ...);
27 int exec_program_v(const char *working_directory,
28 struct strbuf *output, struct strbuf *error_output,
29 int flags, const char **argv);