Skip to content
Snippets Groups Projects
Commit 99964592 authored by Martyn Gigg's avatar Martyn Gigg
Browse files

Remove GUI state files before each build on builders

parent cdef4745
No related branches found
No related tags found
No related merge requests found
......@@ -363,6 +363,16 @@ fi
# Prevent race conditions when creating the user config directory
userconfig_dir=$HOME/.mantid
rm -fr $userconfig_dir
# Remove GUI qsettings files
if [[ ${ON_MACOS} == true ]] ; then
rm -f $HOME/Library/Preferences/com.mantid.MantidPlot.plist
rm -f $HOME/Library/Preferences/org.mantidproject.MantidPlot.plist
rm -f "$HOME/Library/Saved Application State/org.mantidproject.MantidPlot.savedState/windows.plist"
else
rm -f ~/.config/Mantid/MantidPlot.conf
fi
rm -f ~/.config/mantidproject/mantidworkbench.ini
mkdir -p $userconfig_dir
# use a fixed number of openmp threads to avoid overloading the system
userprops_file=$userconfig_dir/Mantid.user.properties
......
......@@ -201,9 +201,10 @@ if ERRORLEVEL 1 exit /B %ERRORLEVEL%
:: This prevents race conditions when creating the user config directory
set USERPROPS=bin\%BUILD_CONFIG%\Mantid.user.properties
del %USERPROPS%
set CONFIGDIR=%APPDATA%\mantidproject\mantid
set CONFIGDIR=%APPDATA%\mantidproject
rmdir /S /Q %CONFIGDIR%
mkdir %CONFIGDIR%
:: Create the directory to avoid any race conditions
mkdir %CONFIGDIR%\mantid
:: use a fixed number of openmp threads to avoid overloading the system
echo MultiThreaded.MaxCores=2 > %USERPROPS%
......
......@@ -74,15 +74,25 @@ ${CMAKE_EXE} --build . -- SystemTestData
###############################################################################
# Run the tests
###############################################################################
# Remove any Mantid.user.properties file
userprops=~/.mantid/Mantid.user.properties
rm -f $userprops
# Remove any user settings
userconfig_dir=$HOME/.mantid
rm -fr $userconfig_dir
# Remove GUI qsettings files
if [[ ${ON_MACOS} == true ]] ; then
rm -f $HOME/Library/Preferences/com.mantid.MantidPlot.plist
rm -f $HOME/Library/Preferences/org.mantidproject.MantidPlot.plist
rm -f "$HOME/Library/Saved Application State/org.mantidproject.MantidPlot.savedState/windows.plist"
else
rm -f ~/.config/Mantid/MantidPlot.conf
fi
rm -f ~/.config/mantidproject/mantidworkbench.ini
# Turn off any auto updating on startup
mkdir -p $userconfig_dir
userprops=$userconfig_dir/Mantid.user.properties
echo "UpdateInstrumentDefinitions.OnStartup = 0" > $userprops
echo "usagereports.enabled = 0" >> $userprops
echo "CheckMantidVersion.OnStartup = 0" >> $userprops
# Remove user instrument directory
rm -fr ~/.mantid/instrument
# Remove mismatch files which have not been cleaned up yet
default_save_directory=${WORKSPACE}/build/Testing/SystemTests/scripts/
......
......@@ -67,6 +67,12 @@ if ERRORLEVEL 1 exit /b %ERRORLEVEL%
set USERPROPS_RELEASE=C:\MantidInstall\bin\Mantid.user.properties
set USERPROPS_NIGHTLY=C:\MantidNightlyInstall\bin\Mantid.user.properties
del /Q %USERPROPS_RELEASE% %USERPROPS_NIGHTLY%
:: Remove user settings
set CONFIGDIR=%APPDATA%\mantidproject
rmdir /S /Q %CONFIGDIR%
:: Create the directory to avoid any race conditions
mkdir %CONFIGDIR%\mantid
:: Turn off any auto updating on startup
echo UpdateInstrumentDefinitions.OnStartup = 0 > %USERPROPS_RELEASE%
echo usagereports.enabled = 0 >> %USERPROPS_RELEASE%
......@@ -75,9 +81,6 @@ echo CheckMantidVersion.OnStartup = 0 >> %USERPROPS_RELEASE%
echo UpdateInstrumentDefinitions.OnStartup = 0 > %USERPROPS_NIGHTLY%
echo usagereports.enabled = 0 >> %USERPROPS_NIGHTLY%
echo CheckMantidVersion.OnStartup = 0 >> %USERPROPS_NIGHTLY%
:: Remove user instrument directory
rmdir /S /Q %APPDATA%\mantidproject\mantid\instrument
:: Run
set PKGDIR=%WORKSPACE%\build
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment