From c4eff86e53e89514ab5f6e97d07f109d02b0958f Mon Sep 17 00:00:00 2001 From: Henrique Bremenkanp Date: Wed, 16 Nov 2016 22:51:12 -0200 Subject: [PATCH] Fix tests --- recipe/common.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/recipe/common.php b/recipe/common.php index fab017bf..2e617df7 100644 --- a/recipe/common.php +++ b/recipe/common.php @@ -345,8 +345,11 @@ task('deploy:shared', function () { $sharedPath = "{{deploy_path}}/shared"; foreach (get('shared_dirs') as $dir) { - // Copy shared dir if it does not exist. - run("if [ -d $(echo {{release_path}}/$dir) ]; then cp -rn {{release_path}}/$dir $sharedPath/$dir; fi"); + // Create shared dir if it does not exist. + run("mkdir -p $sharedPath/$dir"); + + // Copy shared dir files if they does not exist. + run("if [ -d $(echo {{release_path}}/$dir) ]; then cp -rn {{release_path}}/$dir $sharedPath; fi"); // Remove from source. run("if [ -d $(echo {{release_path}}/$dir) ]; then rm -rf {{release_path}}/$dir; fi");