Skip to content

Commit

Permalink
chore: setting timeout for retrieving cache. updating cli command
Browse files Browse the repository at this point in the history
  • Loading branch information
ruisebas committed Aug 30, 2023
1 parent ffe3f18 commit 7fa05a8
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 11 deletions.
17 changes: 6 additions & 11 deletions .github/workflows/build_amplify_swift_for_testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@ on:
type: string
workflow_dispatch:
push:
branches-ignore:
- main
- release
# branches:
# - main

permissions:
contents: read
Expand Down Expand Up @@ -60,8 +59,7 @@ jobs:
GH_TOKEN: ${{ github.token }}
continue-on-error: true
run: |
gh extension install actions/gh-actions-cache
gh actions-cache delete ${{ steps.cache-build.outputs.cache-primary-key }} --confirm
gh cache delete ${{ steps.cache-build.outputs.cache-primary-key }} --confirm
shell: bash
- name: Save the build cache
uses: actions/cache/save@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
Expand Down Expand Up @@ -110,8 +108,7 @@ jobs:
GH_TOKEN: ${{ github.token }}
continue-on-error: true
run: |
gh extension install actions/gh-actions-cache
gh actions-cache delete ${{ steps.cache-build.outputs.cache-primary-key }} --confirm
gh cache delete ${{ steps.cache-build.outputs.cache-primary-key }} --confirm
shell: bash
- name: Save the build cache
uses: actions/cache/save@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
Expand Down Expand Up @@ -160,8 +157,7 @@ jobs:
GH_TOKEN: ${{ github.token }}
continue-on-error: true
run: |
gh extension install actions/gh-actions-cache
gh actions-cache delete ${{ steps.cache-build.outputs.cache-primary-key }} --confirm
gh cache delete ${{ steps.cache-build.outputs.cache-primary-key }} --confirm
shell: bash
- name: Save the build cache
uses: actions/cache/save@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
Expand Down Expand Up @@ -210,8 +206,7 @@ jobs:
GH_TOKEN: ${{ github.token }}
continue-on-error: true
run: |
gh extension install actions/gh-actions-cache
gh actions-cache delete ${{ steps.cache-build.outputs.cache-primary-key }} --confirm
gh cache delete ${{ steps.cache-build.outputs.cache-primary-key }} --confirm
shell: bash
- name: Save the build cache
uses: actions/cache/save@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
Expand Down
10 changes: 10 additions & 0 deletions .github/workflows/run_xcodebuild_test_platforms.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,11 @@ on:
env:
SCHEME: ${{ inputs.scheme }}
RETRY_ON_ERROR: ${{ inputs.retry_on_error }}
SEGMENT_DOWNLOAD_TIMEOUT_MINS: 3

permissions:
contents: read
actions: write

jobs:
test-iOS:
Expand All @@ -54,13 +56,15 @@ jobs:
amplify-packages-
- name: Attempt to restore the scheme build cache
id: restore-build
timeout-minutes: 4
uses: actions/cache/restore@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: ${{ github.workspace }}/Build
key: ${{ env.SCHEME }}-iOS-build-${{ github.sha }}
- name: Attempt to restore the Amplify build cache
if: steps.restore-build.outputs.cache-hit != true
id: restore-amplify-build
timeout-minutes: 4
uses: actions/cache/restore@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: ${{ github.workspace }}/Build
Expand Down Expand Up @@ -129,13 +133,15 @@ jobs:
amplify-packages-
- name: Attempt to restore the scheme build cache
id: restore-build
timeout-minutes: 4
uses: actions/cache/restore@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: ${{ github.workspace }}/Build
key: ${{ env.SCHEME }}-macOS-build-${{ github.sha }}
- name: Attempt to restore the Amplify build cache
if: steps.restore-build.outputs.cache-hit != true
id: restore-amplify-build
timeout-minutes: 4
uses: actions/cache/restore@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: ${{ github.workspace }}/Build
Expand Down Expand Up @@ -195,13 +201,15 @@ jobs:
amplify-packages-
- name: Attempt to restore the scheme build cache
id: restore-build
timeout-minutes: 4
uses: actions/cache/restore@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: ${{ github.workspace }}/Build
key: ${{ env.SCHEME }}-tvOS-build-${{ github.sha }}
- name: Attempt to restore the Amplify build cache
if: steps.restore-build.outputs.cache-hit != true
id: restore-amplify-build
timeout-minutes: 4
uses: actions/cache/restore@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: ${{ github.workspace }}/Build
Expand Down Expand Up @@ -261,13 +269,15 @@ jobs:
amplify-packages-
- name: Attempt to restore the scheme build cache
id: restore-build
timeout-minutes: 4
uses: actions/cache/restore@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: ${{ github.workspace }}/Build
key: ${{ env.SCHEME }}-watchOS-build-${{ github.sha }}
- name: Attempt to restore the Amplify build cache
if: steps.restore-build.outputs.cache-hit != true
id: restore-amplify-build
timeout-minutes: 4
uses: actions/cache/restore@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: ${{ github.workspace }}/Build
Expand Down

0 comments on commit 7fa05a8

Please sign in to comment.