From 5e66f7728025018e058a6279c9d87252eba9ce25 Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Fri, 5 May 2017 10:56:41 +0000 Subject: [PATCH] #1343 @0.25 --- inc/ws/Controlleur/class.ws.maintenance.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/inc/ws/Controlleur/class.ws.maintenance.php b/inc/ws/Controlleur/class.ws.maintenance.php index a33014150..355c9e34c 100644 --- a/inc/ws/Controlleur/class.ws.maintenance.php +++ b/inc/ws/Controlleur/class.ws.maintenance.php @@ -891,13 +891,17 @@ class wsMaintenance { } $branches = array_keys($branches); foreach ($branches as $b) { + $git = $branchesDir . $b; + $local = $localDir . $b; echo '' . $b . '' . "\n"; if (!file_exists($branchesDir . $b)) { $git = new CubeIT_CommandLine_Git($branchesDir); echo $git->executeCmd('clone -b ' . $b . ' --single-branch git@git.cubedesigners.com:fluidbook-html5.git ' . $b); } - if (!file_exists($localDir . $b)) { - mkdir($localDir . $b, 0777, true); + if (!file_exists($local)) { + mkdir($local, 0777, true); + `cp -r $git/* $local`; + `rm -rf $local/.git`; } $git = new CubeIT_CommandLine_Git($branchesDir . $b); echo $git->executeCmd('reset --hard origin/' . $b); -- 2.39.5