diff options
author | Gordon MacPherson <gordon@gordonite.tech> | 2020-07-24 00:15:23 +0100 |
---|---|---|
committer | Gordon MacPherson <gordon@gordonite.tech> | 2020-07-24 00:15:23 +0100 |
commit | afdce1e30c3ddf8e68d5dade28f81bd3a6c3e2ab (patch) | |
tree | 687ddd1dc9e93d217ef40622a97d293436d699e1 /.github/workflows | |
parent | 3c07d0ff325598027e4cd7b5204726cb585e056e (diff) |
Improve the cache keys to prevent clashes for the wrong type of build
Diffstat (limited to '.github/workflows')
-rw-r--r-- | .github/workflows/android_builds.yml | 8 | ||||
-rw-r--r-- | .github/workflows/javascript_builds.yml | 5 | ||||
-rw-r--r-- | .github/workflows/linux_builds.yml | 16 | ||||
-rw-r--r-- | .github/workflows/macos_builds.yml | 16 | ||||
-rw-r--r-- | .github/workflows/windows_builds.yml | 16 |
5 files changed, 31 insertions, 30 deletions
diff --git a/.github/workflows/android_builds.yml b/.github/workflows/android_builds.yml index ebe91702de..6fd2ce7239 100644 --- a/.github/workflows/android_builds.yml +++ b/.github/workflows/android_builds.yml @@ -43,11 +43,11 @@ jobs: uses: actions/cache@v2 with: path: ${{github.workspace}}/.scons_cache/ - key: ${{runner.os}}-template-${{github.sha}} + key: ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} restore-keys: | - ${{runner.os}}-template-${{github.sha}} - ${{runner.os}}-template - ${{runner.os}} + ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/} + ${{github.job}} # Use python 3.x release (works cross platform) - name: Set up Python 3.x diff --git a/.github/workflows/javascript_builds.yml b/.github/workflows/javascript_builds.yml index 19fa6c34fd..5a72b96eb8 100644 --- a/.github/workflows/javascript_builds.yml +++ b/.github/workflows/javascript_builds.yml @@ -29,9 +29,10 @@ jobs: uses: actions/cache@v2 with: path: ${{github.workspace}}/.scons_cache/ - key: ${{github.job}}-${{github.sha}} + key: ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} restore-keys: | - ${{github.job}}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/} ${{github.job}} # Additional cache for Emscripten generated system libraries diff --git a/.github/workflows/linux_builds.yml b/.github/workflows/linux_builds.yml index 6f6f4669f7..1d2d5a3fa7 100644 --- a/.github/workflows/linux_builds.yml +++ b/.github/workflows/linux_builds.yml @@ -33,11 +33,11 @@ jobs: uses: actions/cache@v2 with: path: ${{github.workspace}}/.scons_cache/ - key: ${{runner.os}}-editor-${{github.sha}} + key: ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} restore-keys: | - ${{runner.os}}-editor-${{github.sha}} - ${{runner.os}}-editor - ${{runner.os}} + ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/} + ${{github.job}} # Use python 3.x release (works cross platform; best to keep self contained in it's own step) - name: Set up Python 3.x @@ -90,11 +90,11 @@ jobs: uses: actions/cache@v2 with: path: ${{github.workspace}}/.scons_cache/ - key: ${{runner.os}}-template-${{github.sha}} + key: ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} restore-keys: | - ${{runner.os}}-template-${{github.sha}} - ${{runner.os}}-template - ${{runner.os}} + ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/} + ${{github.job}} # Use python 3.x release (works cross platform) - name: Set up Python 3.x diff --git a/.github/workflows/macos_builds.yml b/.github/workflows/macos_builds.yml index 392a3da595..b896732ffc 100644 --- a/.github/workflows/macos_builds.yml +++ b/.github/workflows/macos_builds.yml @@ -22,11 +22,11 @@ jobs: uses: actions/cache@v2 with: path: ${{github.workspace}}/.scons_cache/ - key: ${{runner.os}}-editor-${{github.sha}} + key: ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} restore-keys: | - ${{runner.os}}-editor-${{github.sha}} - ${{runner.os}}-editor - ${{runner.os}} + ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/} + ${{github.job}} # Use python 3.x release (works cross platform; best to keep self contained in it's own step) - name: Set up Python 3.x @@ -67,11 +67,11 @@ jobs: uses: actions/cache@v2 with: path: ${{github.workspace}}/.scons_cache/ - key: ${{runner.os}}-template-${{github.sha}} + key: ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} restore-keys: | - ${{runner.os}}-template-${{github.sha}} - ${{runner.os}}-template - ${{runner.os}} + ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/} + ${{github.job}} # Use python 3.x release (works cross platform) - name: Set up Python 3.x diff --git a/.github/workflows/windows_builds.yml b/.github/workflows/windows_builds.yml index 0f707062ec..611684debb 100644 --- a/.github/workflows/windows_builds.yml +++ b/.github/workflows/windows_builds.yml @@ -26,11 +26,11 @@ jobs: uses: RevoluPowered/cache@v2.1 with: path: /.scons_cache/ - key: ${{runner.os}}-editor-${{github.sha}} + key: ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} restore-keys: | - ${{runner.os}}-editor-${{github.sha}} - ${{runner.os}}-editor - ${{runner.os}} + ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/} + ${{github.job}} # Use python 3.x release (works cross platform; best to keep self contained in it's own step) - name: Set up Python 3.x @@ -80,11 +80,11 @@ jobs: uses: RevoluPowered/cache@v2.1 with: path: /.scons_cache/ - key: ${{runner.os}}-template-${{github.sha}} + key: ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} restore-keys: | - ${{runner.os}}-template-${{github.sha}} - ${{runner.os}}-template - ${{runner.os}} + ${{github.job}}-${GITHUB_REF##*/}-${{github.sha}} + ${{github.job}}-${GITHUB_REF##*/} + ${{github.job}} # Use python 3.x release (works cross platform) - name: Set up Python 3.x |