Commit 0a61479c authored by Stephane ALBERT's avatar Stephane ALBERT
Browse files

ENH: CI: Fixed order of some git commands.

No related merge requests found
Showing with 9 additions and 7 deletions
+9 -7
...@@ -58,12 +58,20 @@ set (CTEST_INSTALL_DIRECTORY "${CI_ROOT_DIR}/xdk/") ...@@ -58,12 +58,20 @@ set (CTEST_INSTALL_DIRECTORY "${CI_ROOT_DIR}/xdk/")
# This is needed because when using return() function ctest is trying # This is needed because when using return() function ctest is trying
# to run the CTEST_COMMAND. And we need it to not produce an error # to run the CTEST_COMMAND. And we need it to not produce an error
set (CTEST_COMMAND "echo \"Exit\"") # HACK FIX ME set (CTEST_COMMAND "echo \"Exit\"") # HACK FIX ME
set (CMAKE_COMMAND "cmake")######################################################################## set (CMAKE_COMMAND "cmake")
########################################################################
######################################################################## ########################################################################
# Build process # Build process
######################################################################## ########################################################################
######################################################################## ########################################################################
# Look for a GIT command-line client.
find_program(CTEST_GIT_COMMAND NAMES git git.cmd)
# FIXME: Replace ${GIT} variable with $[CTEST_GIT_COMMAND}"
set( GIT "${CTEST_GIT_COMMAND}" )
# Sources are already checked out : do nothing for update # Sources are already checked out : do nothing for update
set(CTEST_GIT_UPDATE_CUSTOM echo No update) set(CTEST_GIT_UPDATE_CUSTOM echo No update)
...@@ -126,12 +134,6 @@ message( "Checking out git for existence of archive") ...@@ -126,12 +134,6 @@ message( "Checking out git for existence of archive")
set ( REMOTE "https://gitlab.orfeo-toolbox.org/gbonnefille/superbuild-artifact/") set ( REMOTE "https://gitlab.orfeo-toolbox.org/gbonnefille/superbuild-artifact/")
set ( BRANCH_NAME "${IMAGE_NAME}/${SB_MD5}") set ( BRANCH_NAME "${IMAGE_NAME}/${SB_MD5}")
# Look for a GIT command-line client.
find_program(CTEST_GIT_COMMAND NAMES git git.cmd)
# FIXME: Replace ${GIT} variable with $[CTEST_GIT_COMMAND}"
set( GIT "git" )
execute_process( execute_process(
COMMAND ${GIT} "ls-remote" "${REMOTE}" "${BRANCH_NAME}" COMMAND ${GIT} "ls-remote" "${REMOTE}" "${BRANCH_NAME}"
OUTPUT_VARIABLE IS_SB_BUILD OUTPUT_VARIABLE IS_SB_BUILD
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment