Skip to content

Commit

Permalink
Update actions-ci.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
andreasweishaupt committed Oct 21, 2024
1 parent f667a75 commit 664227c
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/actions-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -95,19 +95,20 @@ jobs:
uses: actions/cache@v4
id: chrome-cache
with:
path: /tmp/${CHROME_DEB}
path: /tmp/chrome
key: ${{ runner.os }}-chrome-${{ env.CHROME_URL }}

- name: Handle Chrome download or cache
run: |
mkdir -p /tmp/chrome
touch /tmp/chrome_download_progress.log
if [ "${{ steps.chrome-cache.outputs.cache-hit }}" == 'true' ]; then
echo "Chrome loaded from cache"
echo "DONE" > /tmp/chrome_download_progress.log
else
echo "Downloading Chrome..."
(
curl -L "${CHROME_URL}" -o "/tmp/${CHROME_DEB}" --progress-bar 2>&1 | tee /tmp/chrome_download_progress.log > /dev/null
curl -L "${CHROME_URL}" -o "/tmp/chrome/${CHROME_DEB}" --progress-bar 2>&1 | tee /tmp/chrome_download_progress.log > /dev/null
echo "DONE" >> /tmp/chrome_download_progress.log
) &
fi
Expand Down Expand Up @@ -294,8 +295,8 @@ jobs:
sleep 2
done
if [ -f "/tmp/${CHROME_DEB}" ]; then
file_size=$(du -h "/tmp/${CHROME_DEB}" | cut -f1)
if [ -f "/tmp/chrome/${CHROME_DEB}" ]; then
file_size=$(du -h "/tmp/chrome/${CHROME_DEB}" | cut -f1)
echo "Chrome downloaded successfully. File size: $file_size"
else
echo "Download failed"
Expand Down

0 comments on commit 664227c

Please sign in to comment.