mirror of https://github.com/CGAL/cgal
add test to check the field project in cmake scripts
This commit is contained in:
parent
7e2ee496de
commit
de8d0d33f5
|
|
@ -82,6 +82,28 @@ else
|
|||
echo 'No new files.'
|
||||
fi
|
||||
|
||||
project_name_tests=$(for i in */test/*/CMakeLists.txt; do pkg=$(echo $i | awk -F "/" '{print $3}'); grep ${pkg}_Tests -L $i; done)
|
||||
project_name_examples=$(for i in */examples/*/CMakeLists.txt; do pkg=$(echo $i | awk -F "/" '{print $3}'); grep ${pkg}_Examples -L $i; done)
|
||||
project_name_demo=$(for i in */demo/*/CMakeLists.txt; do pkg=$(echo $i | awk -F "/" '{print $3}'); grep ${pkg}_Demo -L $i; done)
|
||||
|
||||
if [ -n "${project_name_tests}" ]; do
|
||||
echo "CMakeLists with incorrect project name"
|
||||
echo ${project_name_tests}
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -n "${project_name_examples}" ]; do
|
||||
echo "CMakeLists with incorrect project name"
|
||||
echo ${project_name_examples}
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -n "${project_name_demo}" ]; do
|
||||
echo "CMakeLists with incorrect project name"
|
||||
echo ${project_name_demo}
|
||||
exit 1
|
||||
fi
|
||||
|
||||
current_rev=$(${git} rev-parse HEAD)
|
||||
trap 'echo "(aborting the merge now)" && ${git} reset --quiet --hard ${current_rev}' EXIT
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue