Skip to content

Commit

Permalink
fix: compare versions in prod build script
Browse files Browse the repository at this point in the history
  • Loading branch information
MohamadJaara committed Dec 3, 2024
1 parent 04294e9 commit f719727
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build-prod-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ jobs:
run: |
current_tag=${{ github.event.release.tag_name }}
latest_tag=${{ steps.get_latest_release.outputs.latest_tag }}
if [[ "$current_tag" != "$(echo -e "$current_tag\n$latest_tag" | sort -V | head -n1)" ]]; then
compare_result=$(printf "%s\n%s" "$current_tag" "$latest_tag" | sort -V | tail -n1)
if [[ "$current_tag" != "$compare_result" ]]; then
echo "Current tag ($current_tag) is lower than latest tag ($latest_tag). Failing the workflow."
exit 1
else
Expand Down

0 comments on commit f719727

Please sign in to comment.