Skip to content

Commit

Permalink
Update publish_new_release.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterNjeim authored Jul 7, 2024
1 parent 70a72d4 commit 85f48e7
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/publish_new_release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,10 @@ jobs:
id: get-latest-release
run: |
echo "updated=false" >> $GITHUB_ENV
echo "CURRENT_VERSION=$(curl -s -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/LibreScore/app-librescore/releases/latest | jq --raw-output ".tag_name")" >> "$GITHUB_OUTPUT"
echo "LATEST_VERSION=$(curl -s -u ${{ secrets.LIBRESCORE_USERNAME }}:${{ secrets.LIBRESCORE_TOKEN }} -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/LibreScore/${{ secrets.LIBRESCORE_REPO_A }}/releases/latest | jq --raw-output ".tag_name")" >> "$GITHUB_OUTPUT"
CURRENT_VERSION="$(curl -s -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/LibreScore/app-librescore/releases/latest | jq --raw-output ".tag_name")"
LATEST_VERSION="$(curl -s -u ${{ secrets.LIBRESCORE_USERNAME }}:${{ secrets.LIBRESCORE_TOKEN }} -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/LibreScore/${{ secrets.LIBRESCORE_REPO_A }}/releases/latest | jq --raw-output ".tag_name")"
echo "CURRENT_VERSION=$CURRENT_VERSION" >> "$GITHUB_OUTPUT"
echo "LATEST_VERSION=$LATEST_VERSION" >> "$GITHUB_OUTPUT"
if [[ ${{ steps.get-latest-release.outputs.CURRENT_VERSION }} != ${{ steps.get-latest-release.outputs.LATEST_VERSION }} ]]; then
echo "updated=true" >> $GITHUB_ENV
fi
Expand Down

0 comments on commit 85f48e7

Please sign in to comment.