From a8ef2c9aa071886d041978c61aa7b76950df1ead Mon Sep 17 00:00:00 2001 From: Jason Rivers Date: Tue, 21 Sep 2021 11:44:07 +0100 Subject: [PATCH] fix rm -Rf on Powershell --- Jenkinsfile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 82420fd2..3bf3035f 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -60,12 +60,14 @@ pipeline { label 'Windows' } steps { - powershell 'rm -r -f _ ship' + powershell 'if (Test-Path -Path ship) { rm -r ship }' + powershell 'if (Test-Path -Path _) { rm -r _ }' unstash 'ride-win' unstash 'ride-version' bat './CI/packagescripts/windows/packageWindows.bat' stash name: 'win-ship', includes: 'ship/*' - powershell 'rm -r -f _ ship' + powershell 'rm -r ship' + powershell 'rm -r _' } } }