Skip to content

Commit

Permalink
Use absolute path for running generate_prerelease_script.py
Browse files Browse the repository at this point in the history
  • Loading branch information
mathias-luedtke committed Aug 4, 2024
1 parent f7bc422 commit ebbaeb7
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions industrial_ci/src/tests/ros_prerelease.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,12 @@
# It is dependent on environment variables that need to be exported in advance
# (As of version 0.4.4 most of them are defined in env.sh).

generate_script_path=/usr/local/bin/generate_prerelease_script.py
function setup_ros_buildfarm() {
ici_install_pkgs_for_command pip3 python3-pip python3-setuptools python3-wheel
ici_cmd ici_quiet ici_asroot pip3 install git+https://github.com/ros-infrastructure/ros_buildfarm.git
if ! [ -e "$generate_script_path" ]; then
ici_install_pkgs_for_command pip3 python3-pip python3-setuptools python3-wheel
ici_cmd ici_quiet ici_asroot pip3 install git+https://github.com/ros-infrastructure/ros_buildfarm.git
fi
}

function setup_ros_prerelease() {
Expand All @@ -41,7 +44,7 @@ function setup_ros_prerelease() {
ici_install_pkgs_for_command docker docker.io
ici_install_pkgs_for_command sudo sudo
ici_install_pkgs_for_command lsb_release lsb-release
ici_exec_for_command generate_prerelease_script.py setup_ros_buildfarm
setup_ros_buildfarm
}

function prepare_prerelease_workspaces() {
Expand Down Expand Up @@ -111,7 +114,7 @@ function run_ros_prerelease() {
local reponame=${PRERELEASE_REPONAME:-$TARGET_REPO_NAME}

ici_step "prepare_prerelease_workspaces" ici_cmd prepare_prerelease_workspaces "$WORKSPACE" "$reponame" "$(basename "$TARGET_REPO_PATH")"
ici_step 'generate_prerelease_script' ici_cmd sudo -EH -u ci generate_prerelease_script.py "${ROSDISTRO_INDEX_URL}" "$PRERELEASE_DISTRO" default "$OS_NAME" "$OS_CODE_NAME" "${OS_ARCH:-amd64}" --build-tool "$BUILDER" --level "$downstream_depth" --output-dir "$WORKSPACE" --custom-repo "$reponame::::"
ici_step 'generate_prerelease_script' ici_cmd sudo -EH -u ci "$generate_script_path" "${ROSDISTRO_INDEX_URL}" "$PRERELEASE_DISTRO" default "$OS_NAME" "$OS_CODE_NAME" "${OS_ARCH:-amd64}" --build-tool "$BUILDER" --level "$downstream_depth" --output-dir "$WORKSPACE" --custom-repo "$reponame::::"

# shellcheck disable=SC2016
ici_asroot sed -i '/test_result_EXECUTABLE="colcon"/a mkdir -p "$WORKSPACE/ws/test_results"' "$WORKSPACE/prerelease_build_underlay.sh"
Expand Down

0 comments on commit ebbaeb7

Please sign in to comment.