Skip to content

Commit

Permalink
workflow: try get pre-releases too
Browse files Browse the repository at this point in the history
  • Loading branch information
belomaxorka committed Feb 7, 2025
1 parent d9a59cd commit ed277f1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ jobs:
id: get-latest-release
run: |
REPO="torrentpier/torrentpier"
LATEST_RELEASE=$(curl -s https://api.github.com/repos/$REPO/releases/latest | jq -r '.tag_name')
RELEASE_DATE=$(curl -s https://api.github.com/repos/$REPO/releases/latest | jq -r '.published_at' | cut -d'T' -f1)
LATEST_RELEASE=$(curl -s https://api.github.com/repos/$REPO/releases | jq -r '.[] | select(.prerelease == true or .prerelease == false) | sort_by(.published_at) | last | .tag_name')
RELEASE_DATE=$(curl -s https://api.github.com/repos/$REPO/releases | jq -r '.[] | select(.prerelease == true or .prerelease == false) | sort_by(.published_at) | last | .published_at' | cut -d'T' -f1)
echo "Latest release version: $LATEST_RELEASE"
echo "Release date: $RELEASE_DATE"
Expand Down

0 comments on commit ed277f1

Please sign in to comment.