Skip to content

Commit f4a1211

Browse files
Merge pull request #238 from ISISComputingGroup/purge_branches
Delete build branches directories
2 parents 0bc913f + 3022f6c commit f4a1211

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

build_tools/purge_archive.bat

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,27 @@ REM use LATEST_PYTHON3 to avoid process being killed
1717
"%LATEST_PYTHON3%" -u "%~dp0purge_archive.py"
1818
set errcode=!errorlevel!
1919
@echo purge_archive.py exited with code !errcode!
20+
21+
@echo Deleting build branches directories
22+
set "KITROOT=\\isis.cclrc.ac.uk\inst$\Kits$\CompGroup\ICP"
23+
pushd %KITROOT%
24+
if !errorlevel! equ 0 (
25+
set MYDIR=!CD!
26+
for /d %%i in ( !MYDIR!\Client_E4 !MYDIR!\genie_python_3 !MYDIR!\script_generator !MYDIR!\Client_E4_win11 ) do (
27+
if exist "%%i\branches" (
28+
forfiles /p "%%i\branches" /d -60 /c "cmd /c del /q /s @path"
29+
)
30+
)
31+
)
32+
popd
33+
2034
for /F "skip=1" %%I in ('wmic path win32_localtime get dayofweek') do (set /a DOW=%%I 2>NUL)
2135
if %DOW% neq 6 (
2236
@echo Skipping debug symbol cleanup as day of week %DOW% is not 6
2337
CALL "%~dp0..\installation_and_upgrade\remove_genie_python.bat" %LATEST_PYTHON_DIR%
2438
exit /b !errcode!
2539
)
40+
2641
REM Remove old debug symbols from the archive
2742
set "AGESTORE=c:\Program Files (x86)\Windows Kits\10\Debuggers\x64\agestore.exe"
2843
set "KITROOT=\\isis.cclrc.ac.uk\inst$\Kits$\CompGroup\ICP"

0 commit comments

Comments
 (0)