workflow: use !cancelled() instead of always()

This commit is contained in:
cy 2025-03-28 18:28:48 -04:00
parent 1537fd6444
commit c6999339da
Signed by: cy
SSH key fingerprint: SHA256:o/geVWV4om1QhUSkKvDQeW/eAihwnjyXkqMwrVdbuts
2 changed files with 6 additions and 3 deletions

View file

@ -70,7 +70,8 @@ jobs:
nix build -L "$package" nix build -L "$package"
- name: cache - name: cache
# if: always() # https://stackoverflow.com/a/58859404
if: '!cancelled()'
run: | run: |
package=".#nixosConfigurations."${{ matrix.machine }}".config.system.build.toplevel" package=".#nixosConfigurations."${{ matrix.machine }}".config.system.build.toplevel"
derivations=() derivations=()
@ -136,7 +137,8 @@ jobs:
nix build -L "$package" nix build -L "$package"
- name: cache - name: cache
# if: always() # https://stackoverflow.com/a/58859404
if: '!cancelled()'
run: | run: |
package=".#homeConfigurations."${{ matrix.home }}".activationPackage" package=".#homeConfigurations."${{ matrix.home }}".activationPackage"
derivations=() derivations=()

View file

@ -59,7 +59,8 @@ jobs:
- run: nix build -L ${{ matrix.package }} - run: nix build -L ${{ matrix.package }}
- name: cache result - name: cache result
if: always() # https://stackoverflow.com/a/58859404
if: '!cancelled()'
run: | run: |
derivations=() derivations=()
while IFS=$'\n' read derivation; do while IFS=$'\n' read derivation; do