Skip to content

Commit

Permalink
Update version-check.yml
Browse files Browse the repository at this point in the history
Set cron to 6h; set timeout for curl
  • Loading branch information
ChrisRomp authored May 18, 2024
1 parent 91b3c84 commit a8e27e3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/version-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Check for Updates

on:
schedule:
- cron: "37 */2 * * *"
- cron: "37 */6 * * *"
workflow_dispatch:

jobs:
Expand All @@ -25,7 +25,7 @@ jobs:
run: |
set -e
echo "Getting version from $VERSION_CHECK_URL"
REMOTE_VERSION=$(curl -s "$VERSION_CHECK_URL" | head -n 1)
REMOTE_VERSION=$(curl -s -m 10 "$VERSION_CHECK_URL" | head -n 1)
echo "Remote version: $REMOTE_VERSION" >> $GITHUB_STEP_SUMMARY
echo "remote_version=$REMOTE_VERSION" >> "$GITHUB_OUTPUT"
Expand All @@ -38,7 +38,7 @@ jobs:
set -e
URL="https://api.github.com/repos/$GITHUB_REPOSITORY/releases/latest"
echo "Getting version from $URL"
CURRENT_VERSION=$(curl -s -H "Authorization: token $GITHUB_TOKEN" "$URL" | jq -r '.tag_name' | sed 's/^v//')
CURRENT_VERSION=$(curl -s -m 10 -H "Authorization: token $GITHUB_TOKEN" "$URL" | jq -r '.tag_name' | sed 's/^v//')
echo "Current version: $CURRENT_VERSION" >> $GITHUB_STEP_SUMMARY
echo "current_version=$CURRENT_VERSION" >> "$GITHUB_OUTPUT"
Expand Down

0 comments on commit a8e27e3

Please sign in to comment.