Retry OSM2ODR download

This commit is contained in:
Xavier Solé Nogués 2024-04-29 14:49:38 +02:00 committed by Blyron
parent e9f6693f1e
commit e351561eea
2 changed files with 8 additions and 16 deletions

View File

@ -92,13 +92,10 @@ if %REMOVE_INTERMEDIATE% == true (
rem Build OSM2ODR rem Build OSM2ODR
if %BUILD_OSM2ODR% == true ( if %BUILD_OSM2ODR% == true (
if %GIT_PULL% == true (
if not exist "%OSM2ODR_SOURCE_PATH%" git clone -b %OSM2ODR_BRANCH% %OSM2ODR_REPO% %OSM2ODR_SOURCE_PATH%
cd "%OSM2ODR_SOURCE_PATH%" cd "%OSM2ODR_SOURCE_PATH%"
git fetch curl --retry 5 --retry-max-time 120 -L -o OSM2ODR.zip https://github.com/carla-simulator/sumo/archive/%CURRENT_OSM2ODR_COMMIT%.zip
git checkout %CURRENT_OSM2ODR_COMMIT% tar -xf OSM2ODR.zip
) cd sumo-%CURRENT_OSM2ODR_COMMIT%
if not exist "%OSM2ODR_VSPROJECT_PATH%" mkdir "%OSM2ODR_VSPROJECT_PATH%" if not exist "%OSM2ODR_VSPROJECT_PATH%" mkdir "%OSM2ODR_VSPROJECT_PATH%"
cd "%OSM2ODR_VSPROJECT_PATH%" cd "%OSM2ODR_VSPROJECT_PATH%"

View File

@ -76,15 +76,10 @@ fi
if ${BUILD_OSM2ODR} ; then if ${BUILD_OSM2ODR} ; then
log "Building OSM2ODR." log "Building OSM2ODR."
# [ ! -d ${OSM2ODR_BUILD_FOLDER} ] && mkdir ${OSM2ODR_BUILD_FOLDER} cd $OSM2ODR_SOURCE_PATH
if ${GIT_PULL} ; then curl --retry 5 --retry-max-time 120 -L -o OSM2ODR.zip https://github.com/carla-simulator/sumo/archive/$CURRENT_OSM2ODR_COMMIT.zip
if [ ! -d ${OSM2ODR_SOURCE_FOLDER} ] ; then tar -xf OSM2ODR.zip
git clone -b ${OSM2ODR_BRANCH} ${OSM2ODR_REPO} ${OSM2ODR_SOURCE_FOLDER} cd sumo-$CURRENT_OSM2ODR_COMMIT
fi
cd ${OSM2ODR_SOURCE_FOLDER}
git fetch
git checkout ${CURRENT_OSM2ODR_COMMIT}
fi
mkdir -p ${OSM2ODR_BUILD_FOLDER} mkdir -p ${OSM2ODR_BUILD_FOLDER}
cd ${OSM2ODR_BUILD_FOLDER} cd ${OSM2ODR_BUILD_FOLDER}