Skip to content

Commit

Permalink
Merge pull request #34 from mpepping/trim-whitespace
Browse files Browse the repository at this point in the history
Removes trailing whitespace

Co-authored-by: Michael Eersink <[email protected]>
Co-authored-by: Martijn Pepping <[email protected]>
  • Loading branch information
mpepping and Michael Eersink authored Sep 15, 2023
2 parents 4a04488 + ed2fe42 commit bf6b376
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,24 +22,24 @@ jobs:
run: |
# Fetch the latest release information from the target repository
RESPONSE=$(curl --silent --fail "https://api.github.com/repos/gchq/CyberChef/releases/latest")
if [ $? -ne 0 ]; then
echo "Failed to fetch the latest release information."
exit 1
fi
# Extract the "published_at" field using jq
PUBLISHED_AT=$(echo "$RESPONSE" | jq -r '.published_at')
# Convert the published_at to Unix timestamp
PUBLISHED_TIMESTAMP=$(date -d "$PUBLISHED_AT" +%s)
# Get the current time and convert it to Unix timestamp
CURRENT_TIMESTAMP=$(date +%s)
# Calculate the difference in seconds
TIME_DIFF=$(expr "$CURRENT_TIMESTAMP" - "$PUBLISHED_TIMESTAMP")
# If the difference is less than 86400 seconds (24 hours), proceed with the next steps
if [ $TIME_DIFF -le 86400 ]; then
echo "New release detected. Proceeding with the next steps."
Expand All @@ -48,7 +48,7 @@ jobs:
echo "No new release in the last 24 hours."
echo "proceed=false" >> $GITHUB_OUTPUT
fi
- name: Set up QEMU
if: steps.check_release.outputs.proceed == 'true'
uses: docker/setup-qemu-action@v3
Expand Down Expand Up @@ -81,7 +81,7 @@ jobs:
run: echo "TAG=docker.io/mpepping/cyberchef:${VERSION}" >> $GITHUB_ENV

- name: Build and push
if: steps.check_release.outputs.proceed == 'true'
if: steps.check_release.outputs.proceed == 'true'
timeout-minutes: 720
uses: docker/build-push-action@v5
with:
Expand Down

0 comments on commit bf6b376

Please sign in to comment.