From bf118c40df0edf61214b1c5366fbe6d777fe4897 Mon Sep 17 00:00:00 2001 From: peterpeter Date: Sat, 25 Jun 2016 22:44:10 +0200 Subject: [PATCH] Fix if 'git' instead of 'git.exe' as command is used on windows (#168) --- RoboFile.php | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/RoboFile.php b/RoboFile.php index dd9a76d..c92ada8 100644 --- a/RoboFile.php +++ b/RoboFile.php @@ -66,9 +66,17 @@ class RoboFile extends \Robo\Tasks { if ($this->isWindows()) { - return '.exe'; + // check wehter git.exe or git as command should be used, + // as on window both is possible + if(!$this->_exec('git.exe --version')->getMessage()) + { + return ''; + } + else + { + return '.exe'; + } } - return ''; }