aboutsummaryrefslogtreecommitdiff
path: root/bdep/git.txx
diff options
context:
space:
mode:
Diffstat (limited to 'bdep/git.txx')
-rw-r--r--bdep/git.txx6
1 files changed, 4 insertions, 2 deletions
diff --git a/bdep/git.txx b/bdep/git.txx
index ef81bd8..2af8e1f 100644
--- a/bdep/git.txx
+++ b/bdep/git.txx
@@ -8,7 +8,7 @@ namespace bdep
run_git (const semantic_version& min_ver,
bool system,
bool progress,
- const dir_path& repo,
+ const dir_path* repo,
A&&... args)
{
// Unfortunately git doesn't have any kind of a no-progress option but
@@ -30,10 +30,12 @@ namespace bdep
//
process pr (start_git (min_ver,
system,
- repo,
0 /* stdin */,
err /* stdout */,
err /* stderr */,
+ (repo != nullptr
+ ? cstrings ({"-C", repo->string ().c_str ()})
+ : cstrings ()),
forward<A> (args)...));
bool io (false);