Skip to content

Commit 75fc49e

Browse files
Use cancelled() instead of always() as much as possible
1 parent 078e68e commit 75fc49e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

.github/workflows/build-toolchain.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ jobs:
6565
name: Build matrix
6666
needs: [start-runner]
6767
runs-on: ubuntu-latest
68-
if: ${{ always() }}
68+
if: ${{ !cancelled() }}
6969
outputs:
7070
entries: ${{ steps.generate.outputs.entries }}
7171
steps:
@@ -99,7 +99,7 @@ jobs:
9999
# https://github.com/actions/cache/blob/main/tips-and-workarounds.md#cache-segment-restore-timeout
100100
SEGMENT_DOWNLOAD_TIMEOUT_MINS: 30
101101
needs: [build-matrix]
102-
if: ${{ always() }}
102+
if: ${{ !cancelled() }}
103103
strategy:
104104
fail-fast: false
105105
matrix:
@@ -196,7 +196,7 @@ jobs:
196196
docker cp swiftwasm-ci-buildbot:/home/build-user/swift-wasm-${{ matrix.toolchain_channel }}-SNAPSHOT-${{ matrix.target }}.tar.gz .
197197
198198
- name: Extract build-cache from Docker container
199-
if: ${{ matrix.container != null && always() }}
199+
if: ${{ matrix.container != null && !cancelled() }}
200200
run: |
201201
rm -rf ${{ github.workspace }}/build-cache
202202
docker cp swiftwasm-ci-buildbot:/home/build-user/build-cache ${{ github.workspace }}/build-cache
@@ -209,7 +209,7 @@ jobs:
209209
run: ./swiftwasm-build/tools/build/ci.sh ${{ matrix.scheme }}
210210

211211
- uses: actions/cache/save@v3
212-
if: ${{ always() }}
212+
if: ${{ !cancelled() }}
213213
with:
214214
path: build-cache
215215
key: ${{ steps.cache_key.outputs.SCCACHE_KEY }}

0 commit comments

Comments
 (0)