diff options
Diffstat (limited to 'bdep/git.hxx')
-rw-r--r-- | bdep/git.hxx | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/bdep/git.hxx b/bdep/git.hxx index f56f38b..1552670 100644 --- a/bdep/git.hxx +++ b/bdep/git.hxx @@ -16,12 +16,26 @@ namespace bdep bool git (const dir_path&); + template <typename... A> + inline void + run_git (const dir_path& repo, A&&... args); + + template <typename I, typename O, typename E, typename... A> + inline process + start_git (I&& in, O&& out, E&& err, const dir_path& repo, A&&... args); + // Return the first line of the git output. If ignore_error is true, then - // suppress stderr, ignore (normal) error exist status, and return nullopt. + // suppress stderr, ignore (normal) error exit status, and return nullopt. // template <typename... A> optional<string> git_line (const dir_path& repo, bool ignore_error, A&&... args); + + // Similar to the above but takes the already started git process with a + // redirected output pipe. + // + optional<string> + git_line (process&& pr, fdpipe&& pipe, bool ignore_error = false); } #include <bdep/git.ixx> |