#
# Remove temporary files that are generated by build submissions,
# cmake configure and testing
#
# Cleanup old dashboard submissions
FILE(GLOB OLD_DASHBOARDS "@ITK_BINARY_DIR@/Testing/20*")
FOREACH(OLD ${OLD_DASHBOARDS})
  MESSAGE(" Removing old submission in ${OLD}")
  FILE(REMOVE_RECURSE "${OLD}")
ENDFOREACH(OLD ${OLD_DASHBOARDS})

# Cleanup the Testing/Temporary directory
FILE(REMOVE_RECURSE "@ITK_BINARY_DIR@/Testing/Temporary")

# Cleanup the CMake Error and Output logs
FILE(REMOVE "@ITK_BINARY_DIR@${CMAKE_FILES_DIRECTORY}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log")
FILE(REMOVE "@ITK_BINARY_DIR@${CMAKE_FILES_DIRECTORY}/CMakeOutput.log")
FILE(REMOVE "@ITK_BINARY_DIR@/CMakeOutput.log")

FILE(REMOVE "@ITK_BINARY_DIR@${CMAKE_FILES_DIRECTORY}${CMAKE_FILES_DIRECTORY}/CMakeError.log")
FILE(REMOVE "@ITK_BINARY_DIR@${CMAKE_FILES_DIRECTORY}/CMakeError.log")
FILE(REMOVE "@ITK_BINARY_DIR@/CMakeError.log")
