From 583c94a962d155468bb848d00aab5fe5d6eb95c8 Mon Sep 17 00:00:00 2001 From: Christian Weiske Date: Tue, 8 Jul 2014 06:55:57 +0200 Subject: [PATCH] fix git version detection on OSX --- src/phorkie/SetupCheck.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/phorkie/SetupCheck.php b/src/phorkie/SetupCheck.php index 557d85c..c4d365c 100644 --- a/src/phorkie/SetupCheck.php +++ b/src/phorkie/SetupCheck.php @@ -101,8 +101,9 @@ class SetupCheck if ($retval !== 0) { $this->fail('Running git executable failed.'); } - if (!preg_match('#^git version ([0-9.]+(rc[0-9]+)?)$#', $line, $matches)) { + if (!preg_match('#^git version ([0-9.]+(rc[0-9]+)?)(?: \(Apple Git-\d+\))?$#', $line, $matches)) { $this->fail('git version output format unexpected: ' . $line); + return; } if (version_compare($matches[1], '1.7.5') < 0) { $this->fail( -- 2.30.2