Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

include EOL distros in rosdep update #352

Merged
merged 3 commits into from
Feb 2, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions industrial_ci/src/tests/source_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,17 @@ rosdep --version
if ! [ -d /etc/ros/rosdep/sources.list.d ]; then
sudo rosdep init
fi
ret_rosdep=1
rosdep update || while [ $ret_rosdep != 0 ]; do sleep 1; rosdep update && ret_rosdep=0 || echo "rosdep update failed"; done

update_opts=()
case "$ROS_DISTRO" in
"hydro"|"jade")
if rosdep update --help | grep -q -- --include-eol-distros; then
130s marked this conversation as resolved.
Show resolved Hide resolved
update_opts+=(--include-eol-distros)
fi
;;
esac

ici_retry 2 rosdep update "${update_opts[@]}"
130s marked this conversation as resolved.
Show resolved Hide resolved

ici_time_end # setup_rosdep

Expand Down Expand Up @@ -172,7 +181,7 @@ ici_time_start catkin_build

# for catkin
if [ "${TARGET_PKGS// }" == "" ]; then export TARGET_PKGS=`catkin_topological_order ${TARGET_REPO_PATH} --only-names`; fi
# fall-back to all workspace packages if target repo does not contain any packages (#232)
# fall-back to all workspace packages if target repo does not contain any packages (#232)
if [ "${TARGET_PKGS// }" == "" ]; then export TARGET_PKGS=`catkin_topological_order $CATKIN_WORKSPACE/src --only-names`; fi
if [ "${PKGS_DOWNSTREAM// }" == "" ]; then export PKGS_DOWNSTREAM=$( [ "${BUILD_PKGS_WHITELIST// }" == "" ] && echo "$TARGET_PKGS" || echo "$BUILD_PKGS_WHITELIST"); fi
if [ "$BUILDER" == catkin ]; then catkin build $OPT_VI --summarize --no-status $BUILD_PKGS_WHITELIST $CATKIN_PARALLEL_JOBS --make-args $ROS_PARALLEL_JOBS ; fi
Expand Down
14 changes: 14 additions & 0 deletions industrial_ci/src/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,20 @@ function ici_enforce_deprecated {
fi
}

function ici_retry {
local tries=$1; shift
local ret=0

for ((i=1;i<=tries;i++)); do
"$@" && return 0
ret=$?
sleep 1;
done

ici_color_output ${ANSI_RED} "'$*' failed $tries times"
return $ret
130s marked this conversation as resolved.
Show resolved Hide resolved
}

if ! which sudo > /dev/null; then
function sudo {
"$@"
Expand Down