aboutsummaryrefslogtreecommitdiff
path: root/build2/version/snapshot-git.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'build2/version/snapshot-git.cxx')
-rw-r--r--build2/version/snapshot-git.cxx8
1 files changed, 5 insertions, 3 deletions
diff --git a/build2/version/snapshot-git.cxx b/build2/version/snapshot-git.cxx
index 9ff1cc9..bf863ce 100644
--- a/build2/version/snapshot-git.cxx
+++ b/build2/version/snapshot-git.cxx
@@ -30,7 +30,7 @@ namespace build2
{
const char* args[] {"git", "-C", d, "status", "--porcelain", nullptr};
- if (!run<string> (args, [] (string& s) {return move (s);}).empty ())
+ if (!run<string> (3, args, [](string& s) {return move (s);}).empty ())
return r;
}
@@ -49,7 +49,7 @@ namespace build2
const char* args[] {
"git", "-C", d, "cat-file", "commit", "HEAD", nullptr};
- process pr (run_start (args));
+ process pr (run_start (3 /* verbosity */, args, -1 /* stdout */));
try
{
@@ -116,7 +116,9 @@ namespace build2
// that.
}
- if (!run_finish (args, pr) || r.sn == 0)
+ run_finish (args, pr);
+
+ if (r.sn == 0)
fail << "unable to extract git commit id/date for " << src_root;
sha1 cs;