Skip to content

Commit

Permalink
fix(experiment/run-library.sh): Deal better with stream releases
Browse files Browse the repository at this point in the history
  • Loading branch information
pablomh committed Mar 6, 2024
1 parent 01fd980 commit 17d8cb8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions experiment/run-library.sh
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,12 @@ function status_data_create() {
sd_kat_ver="$6"
sd_kat_ver_short=$( echo "$sd_kat_ver" | sed 's/^katello-//' | sed 's/[^0-9.-]//g' | sed 's/^\([0-9]\+\.[0-9]\+\)\..*/\1/' | sed 's/^N\/A$/0.0/' ) # "katello-3.16.0-0.2.master.el7.noarch" -> "3.16"
sd_sat_ver="$7"
if [[ "$(echo "$sd_sat_ver" | awk -F'.' '{print $(NF-2)}')" == 'stream' ]]; then
if [[ "${sd_sat_ver}" == 'stream' ]]; then
sd_sat_ver_short=stream
elif [[ "$(echo "${sd_sat_ver}" | awk -F'.' '{print $(NF-2)}')" == 'stream' ]]; then
sd_sat_ver_short=stream
else
sd_sat_ver_short=$( echo "$sd_sat_ver" | sed 's/^satellite-//' | sed 's/[^0-9.-]//g' | sed 's/^\([0-9]\+\.[0-9]\+\)\..*/\1/' | sed 's/^N\/A$/0.0/' ) # "satellite-6.6.0-1.el7.noarch" -> "6.6"
sd_sat_ver_short=$( echo "${sd_sat_ver}" | sed 's/^satellite-//' | sed 's/[^0-9.-]//g' | sed 's/^\([0-9]\+\.[0-9]\+\)\..*/\1/' | sed 's/^N\/A$/0.0/' ) # "satellite-6.6.0-1.el7.noarch" -> "6.6"
fi
sd_run="$8"
sd_additional="$9"
Expand Down

0 comments on commit 17d8cb8

Please sign in to comment.