From 89cee43d38e84a08751e4329258e867f001f3b0c Mon Sep 17 00:00:00 2001 From: Artem Smirnov Date: Sun, 14 Oct 2018 05:17:48 +0300 Subject: [PATCH] image: Move my repeat func to my_travis_retry --- builder/image-ros.sh | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/builder/image-ros.sh b/builder/image-ros.sh index 6d250c67..1ec9454c 100755 --- a/builder/image-ros.sh +++ b/builder/image-ros.sh @@ -75,20 +75,7 @@ resolve_rosdep() { echo_stamp "Installing dependencies apps with rosdep in ${CATKIN_PATH}" cd ${CATKIN_PATH} - set +e - # Successfull unmount flag (false at thismoment) - install_ok=false - # Repeat 5 times - for i in {1..5}; do - # Resolving Dependencies with rosdep - rosdep install -y --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -r --os=${OS_DISTRO}:${OS_VERSION} \ - && install_ok=true && break || (echo_stamp "rosdep iteration #$i failed!" "ERROR"; sleep 2) - done - set -e - # Stage fail if this condition is not true - [[ $install_ok ]] \ - && echo_stamp "All rosdep dependencies was installed!" "SUCCESS" \ - || (echo_stamp "Rosdep installation was failed!" "ERROR"; exit 1) + my_travis_retry rosdep install -y --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -r --os=${OS_DISTRO}:${OS_VERSION} } INSTALL_ROS_PACK_SOURCES=${INSTALL_ROS_PACK_SOURCES:='false'}