Skip to content

Commit

Permalink
Temporary rule to remove build directory if old layout in use
Browse files Browse the repository at this point in the history
Refs #10870
  • Loading branch information
martyngigg committed Feb 15, 2015
1 parent 759f982 commit d0c3785
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
9 changes: 9 additions & 0 deletions Code/Mantid/Build/Jenkins/buildscript
Expand Up @@ -82,6 +82,15 @@ if [[ ${JOB_NAME} == *clean* ]]; then
CLEANBUILD=true
BUILDPKG=true
fi

if [[ -e $WORKSPACE/build/CMakeCache.txt ]]
# Temporary while the builds flick between old & new TestingTools locations
grep 'Code/Mantid/TestingTools/cxxtest' $WORKSPACE/build/CMakeCache.txt > /dev/null
if [ $? -eq 0 ]; then
rm -fr $WORKSPACE/build
fi
fi

if [[ ${JOB_NAME} == *pull_requests* ]]; then
BUILDPKG=true
fi
Expand Down
8 changes: 8 additions & 0 deletions Code/Mantid/Build/Jenkins/buildscript.bat
Expand Up @@ -37,6 +37,14 @@ if "%JOB_NAME%"=="%JOB_NAME:clean=%" (
set CLEANBUILD=yes
set BUILDPKG=yes
)

if EXIST %WORKSPACE%\build\CMakeCache.txt (
TYPE %WORKSPACE%\build\CMakeCache.txt | FINDSTR "Code/Mantid/TestingTools/cxxtest"
if %ERRORLEVEL% EQU 0 (
rmdir /S /Q %WORKSPACE%\build
)
)

if "%JOB_NAME%"=="%JOB_NAME:pull_requests=%" (
set BUILDPKG=yes
)
Expand Down

0 comments on commit d0c3785

Please sign in to comment.