Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into feature/7363_vates_paraview_git Conflicts: Code/Mantid/Build/Jenkins/buildscript Code/Mantid/Build/Jenkins/buildscript.bat
- Loading branch information
Showing
3,952 changed files
with
213,092 additions
and
83,583 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# - Find Pylint | ||
# Find the Pylint executable and extract the version number | ||
# | ||
# OUTPUT Variables | ||
# | ||
# PYLINT_FOUND | ||
# True if the pylint package was found | ||
# PYLINT_EXECUTABLE | ||
# The pylint executable location | ||
# PYLINT_VERSION | ||
# A string denoting the version of pylint that has been found | ||
# PYLINT_RUNNER_SCRIPT | ||
# Location of python script that will actually run pylint | ||
# PYLINT_CFG_FILE | ||
# Location of configuration file | ||
# | ||
|
||
#============================================================= | ||
# main() | ||
#============================================================= | ||
|
||
find_program ( PYLINT_EXECUTABLE pylint PATHS /usr/bin ) | ||
|
||
if ( PYLINT_EXECUTABLE ) | ||
execute_process ( COMMAND ${PYLINT_EXECUTABLE} --version OUTPUT_VARIABLE PYLINT_VERSION_RAW ERROR_QUIET ) | ||
if (PYLINT_VERSION_RAW) | ||
string ( REGEX REPLACE "^pylint ([0-9]+.[0-9]+.[0-9]+),.*" "\\1" PYLINT_VERSION ${PYLINT_VERSION_RAW}) | ||
else () | ||
set ( PYLINT_VERSION "unknown" ) | ||
endif() | ||
# Script to find all .py files and execute pylint | ||
set ( PYLINT_RUNNER_SCRIPT ${CMAKE_SOURCE_DIR}/../Tools/Pylint/run_pylint.py ) | ||
# Configuration file | ||
set ( PYLINT_CFG_FILE ${CMAKE_SOURCE_DIR}/../Tools/Pylint/pylint.cfg ) | ||
endif () | ||
|
||
include(FindPackageHandleStandardArgs) | ||
FIND_PACKAGE_HANDLE_STANDARD_ARGS ( Pylint DEFAULT_MSG PYLINT_EXECUTABLE ) | ||
|
||
mark_as_advanced ( PYLINT_EXECUTABLE PYLINT_VERSION ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
######################################################## | ||
# Setup target to run pylint checking if it is available | ||
######################################################## | ||
find_package ( Pylint ) | ||
|
||
if ( PYLINT_FOUND AND PYLINT_VERSION VERSION_LESS "1.0.0" ) | ||
message ( STATUS "pylint found but version is < 1.0.0 (${PYLINT_VERSION}): no target generated." ) | ||
set ( PYLINT_FOUND FALSE ) | ||
endif() | ||
|
||
if ( PYLINT_FOUND ) | ||
message ( STATUS "pylint version: ${PYLINT_VERSION}" ) | ||
|
||
# Output format options | ||
if ( NOT PYLINT_OUTPUT_FORMAT ) | ||
# Use msvs for MSVC generator, colorized for everything else. The buildservers can | ||
# set it to parseable for Jenkins | ||
if ( MSVC ) | ||
set ( DEFAULT_FORMAT "msvs" ) | ||
else () | ||
set ( DEFAULT_FORMAT "colorized" ) | ||
endif () | ||
set ( PYLINT_OUTPUT_FORMAT ${DEFAULT_FORMAT} CACHE STRING "Desired pylint output format" ) | ||
|
||
# There are a limited set of allowed options | ||
set_property( CACHE PYLINT_OUTPUT_FORMAT PROPERTY STRINGS "text" "html" "msvs" "parseable" "colorized" ) | ||
endif() | ||
|
||
# add a pylint-check target to run pylint on the required files and directories | ||
# relative to the root source directory | ||
set ( BASE_DIR ${CMAKE_SOURCE_DIR} ) | ||
set ( PYLINT_INCLUDES | ||
Framework/PythonInterface/plugins | ||
scripts | ||
) | ||
set ( PYLINT_EXCLUDES | ||
scripts/lib1to2 | ||
scripts/test | ||
) | ||
add_custom_target ( pylintcheck | ||
COMMAND ${PYTHON_EXECUTABLE} ${PYLINT_RUNNER_SCRIPT} --format=${PYLINT_OUTPUT_FORMAT} | ||
--rcfile=${PYLINT_CFG_FILE} | ||
--mantidpath=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR} | ||
--basedir=${BASE_DIR} --nofail | ||
--exclude="${PYLINT_EXCLUDES}" | ||
${PYLINT_INCLUDES} | ||
COMMENT "Running pylint on selected python files" | ||
) | ||
set_target_properties ( pylintcheck PROPERTIES EXCLUDE_FROM_ALL TRUE ) | ||
endif () |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.