From b74bfe7060fc0c40f5dd09916829658869d5666c Mon Sep 17 00:00:00 2001 From: Freddie Akeroyd Date: Wed, 30 Apr 2025 18:08:38 +0100 Subject: [PATCH] Fix path to avoid Invalid switch - Jenkins error --- build_tools/purge_archive.bat | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/build_tools/purge_archive.bat b/build_tools/purge_archive.bat index 9a74ad07..ccc2a36a 100644 --- a/build_tools/purge_archive.bat +++ b/build_tools/purge_archive.bat @@ -1,12 +1,14 @@ setlocal EnableDelayedExpansion REM Remove old builds from the archive -if "%WORKSPACE%" == "" ( +set "WORKWIN=%WORKSPACE:/=\%" + +if "%WORKWIN%" == "" ( call "%~dp0..\installation_and_upgrade\define_latest_genie_python.bat" ) else ( - if exist "%WORKSPACE%\Python3" rd /s /q %WORKSPACE%\Python3 + if exist "%WORKWIN%\Python3" rd /s /q %WORKWIN%\Python3 if !errorlevel! neq 0 exit /b 1 - call "%~dp0..\installation_and_upgrade\define_latest_genie_python.bat" %WORKSPACE%\Python3 + call "%~dp0..\installation_and_upgrade\define_latest_genie_python.bat" %WORKWIN%\Python3 ) IF %errorlevel% neq 0 EXIT /b %errorlevel%