From 2e98651d624fc73ba3ff8e973690d2b43ff60c06 Mon Sep 17 00:00:00 2001 From: Sebastiaan Janssen Date: Tue, 19 Sep 2017 18:16:19 +0200 Subject: [PATCH] Create the out and tmp folders correctly --- build/Modules/Umbraco.Build/Umbraco.Build.psm1 | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/build/Modules/Umbraco.Build/Umbraco.Build.psm1 b/build/Modules/Umbraco.Build/Umbraco.Build.psm1 index 15f84c06ca..67079aa330 100644 --- a/build/Modules/Umbraco.Build/Umbraco.Build.psm1 +++ b/build/Modules/Umbraco.Build/Umbraco.Build.psm1 @@ -51,13 +51,19 @@ function Prepare-Build if (-not $keep) { - Remove-Directory "$tmp" - mkdir "$tmp" > $null - - Remove-Directory "$out" - mkdir "$out" > $null + Remove-Directory "$tmp" + Remove-Directory "$out" } + if (-not (Test-Path "$tmp")) + { + mkdir "$tmp" > $null + } + if (-not (Test-Path "$out")) + { + mkdir "$out" > $null + } + # ensure proper web.config $webUi = "$src\Umbraco.Web.UI" Store-WebConfig $webUi